Page 1 of 1

Error en algunas propiedades de RichEditBox

Posted: Wed Jun 07, 2023 6:29 pm
by arroya2
Español

Hola.
Hace tiempo que no programo en HMG y hace unos días me han pedido una modificación de una aplicación y al compilar me está dando error en una función que desarrollé que no he modificado.
La aplicación usa el control RichEditBox y los errores se dan en las siguientes propiedades:
- AddTextAndSelect
- ParaLineSpacing
- ParaAlignment
- FontScript
- RtfPrint

En todos me da el error:
- Error E0030 Syntax Error at '.'

Supongo que esos controles ya no existen.

Me pueden ayudar para poder hacer el documento que les voy a subir a continuación, o me pueden decir como puedo hacer el documento con otros controles o de otra forma.

También les voy a subir el código de la función que me da el error.

Muchas gracias.


English

Hello.
I haven't programmed in HMG for a long time and a few days ago they asked me for a modification of an application and when compiling it is giving me an error in a function that I developed that I have not modified.
The application uses the RichEditBox control and the errors are given in the following properties:
- AddTextAndSelect
- ParaLineSpacing
- ParaAlignment
- FontScript
- RtfPrint

In all it gives me the error:
- Error E0030 Syntax Error at '.'

I guess those controls no longer exist.

Can you help me to be able to make the document that I am going to upload next, or can you tell me how I can make the document with other controls or in another way.

I am also going to upload the code of the function that gives me the error.

Thank you so much.

ImpCerAni-2.zip
Código del programa - Program code:
(2.07 KiB) Downloaded 152 times

Document to print:
Prueba 3.zip
Documento a imprimir - Document to print:
(413.94 KiB) Downloaded 156 times

Re: Error en algunas propiedades de RichEditBox

Posted: Wed Jun 07, 2023 8:58 pm
by Red2
Hi arroya2,

Using HMG's 3.4.4 IDE I created an HMG project using your ImpCerAni-2.PRG.
I renamed ImpCerAni-2.PRG to Main.PRG.

1) I had to add dummy stub functions for CODCENTRO(), CODPOBLAMIN(), and IMPMEMBRETE().
2) I comment out the lines that referred to any .DBF fields.
3) I changed STATIC FUNCTION ImpAnvAni() to FUNCTION Main().
4) It then ran and produced a readable .PDF file. Of course much of the contents you wanted was missing.

With the 4 changes (see above) no errors occurred.
Is this at all helpful?
Can you provide more details about your error or code?

Re: Error en algunas propiedades de RichEditBox

Posted: Thu Jun 08, 2023 3:49 pm
by arroya2
Hello Red2.

I have used the version you have used of HMG and it worked for me first time.
Thank you very much for your cooperation.

Very thankful