In order for this site to work correctly we need to store a small file (called a cookie) on your computer. Most every site in the world does this, however since the 25th of May 2011, by law we have to get your permission first. Please abandon the forum if you disagree.

Para que este foro funcione correctamente es necesario guardar un pequeño fichero (llamado cookie) en su ordenador. La mayoría de los sitios de Internet lo hacen, no obstante desde el 25 de Marzo de 2011 y por ley, necesitamos de su permiso con antelación. Abandone este foro si no está conforme.

ActiveX problem

Xailer professional forum in English
Guest

ActiveX problem

Mensaje por Guest »

Hi,
perhaps someone can give me an advise regarding this problem I have with an
ActiveX control:
CLASS TForm1 FROM TForm
COMPONENT oMapSource
COMPONENT oMapControl
...
METHOD CreateForm()
METHOD FormInit( oSender )
ENDCLASS
#include "eTPMain.xfm"
//---------------------------------------------------------- --------------------
METHOD FormInit( oSender ) CLASS TForm1
WITH OBJECT ::oMapSource := TMGCMapSource():New( ::oFldMap )
:Create()
msginfo( :CurrentMapName ) // shows a correct value
END WITH
WITH OBJECT ::oMapControl := TMGCMapControl():New( ::oFldMap )
:nLeft := 0
:nTop := 0
:nWidth := 200
:nHeight := 200
:Create()
:ToolbarVisible := .f.
:nAlign := alClient
END WITH
msginfo( ValType( ::oMapControl )) // returns "O"
// everything works up to now but the next line generates an error
(please see the attached error.log)
::oMapControl:MapSource := ::oMapSource
RETURN Nil
I attached the source code of the MGCMapControl and MGCMapSource classes,
too.
Best regards, Timm.


Attached files ActiveX problem.zip (1.7 KB)Â
Responder