Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
COM Object with UI Called from C++
Message
From
26/05/1999 17:39:34
 
 
To
26/05/1999 17:23:37
General information
Forum:
Visual FoxPro
Category:
ActiveX controls in VFP
Miscellaneous
Thread ID:
00223195
Message ID:
00223203
Views:
23
>I have created a VFP application that uses an OUT-OF-PROCESS server(.exe)
>
>I'm calling my com object from C++, which is no problem.
>My problem is popping up user interface objects.
>
>I checked out www.west-wind.com and I could not find a solution.
>
>BELOW IS MY FOXPRO CODE, and it pops up the messageboxes pop up fine, but the form never pops up. I put messagebox's on the form INIT, DESTROY and they are called.
>
>Any help would be appreciated.
>
>***
>***
>DEFINE CLASS FTComObject AS CUSTOM OLEPUBLIC
>
>nValue=0.00
>
>FUNCTION INIT
> SET CLASSLIB TO testDialog
> ENDFUNC
>
>FUNCTION Release
> SET CLASSLIB TO
> ENDFUNC
>
>FUNCTION AddNumbers
>LPARAMETER LV1,LV2
> THIS.nValue=LV1+LV2
> =MESSAGEBOX(STR(THIS.NVALUE,10,2))
> RETURN THIS.nValue
> ENDFUNC
>
>FUNCTION ShowTestDialog
> =MESSAGEBOX('STARTED')
> LOCAL newform
> newform=CREATEOBJECT('testDialog')
> newform.show(1)
> newform.visible=.t.
> =MESSAGEBOX('Done')
> RETURN 1
> ENDFUNC
>ENDDEFINE

Since the VFP screen is not visible, perhaps you may have to set your form to be a Top Level form... or, you would have to turn the VFP screen on.

BOb
Previous
Reply
Map
View

Click here to load this message in the networking platform