Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Out-Of-VFP execution of ActiveX of Report Manager
Message
From
12/10/2005 09:52:25
Cetin Basoz
Engineerica Inc.
Izmir, Turkey
 
General information
Forum:
Visual FoxPro
Category:
ActiveX controls in VFP
Environment versions
Visual FoxPro:
VFP 6 SP5
Miscellaneous
Thread ID:
01057851
Message ID:
01058301
Views:
10
>Hi
>
>>It isn't my fault:) I said I don't know anything about that OCX. Probably you need a form as a container for it.
>
>No <g> not your fault. Does an ActiveX really require to be on a container in such a situation, can I just activate the ActiveX using CREATEOBJECT() or something. I am just picking your brains for some of your experiences. <g>
>
>
LOCAL loForm, ltTime
>
>
>SET CLASSLIB TO cReportManager.vcx ADDITIVE
>
>
>loForm = CREATEOBJECT("Form")
>loForm.ADDOBJECT("oRM", "ccntReportManager")
>
>
>ltTime = SECONDS()
>
>DO WHILE SECONDS() < m.ltTime + 5
>	?? CHR(7)
>ENDDO
>
>
>loForm.REMOVEOBJECT("oRM")
>
>
>*QUIT
>
>Thanks, the form never showed.
>
>I wasn't able to do this: loForm.oRM = .NULL. before the removeobject(), no probs?
>
>Please suggest on the progress and any ideas you may have.

You don't need to do that. When your work with your object is finished simply release the form and your code would end. ie:
Local loForm, ltTime
*SET CLASSLIB TO cReportManager.vcx ADDITIVE
loForm = CREATEOBJECT("myForm")
loForm.DoSomething()
loForm.DoOtherThing()
loForm.Release()

Define class myForm as Form
    Add object oRM as "ccntReportManager"

    Procedure DoSomething
    ltTime = SECONDS()
    Do WHILE SECONDS() < m.ltTime + 5
     ?? "CHR(7)"
    Enddo
Endproc

    Procedure DoOtherThing()
Endproc
Enddefine
Cetin
Çetin Basöz

The way to Go
Flutter - For mobile, web and desktop.
World's most advanced open source relational database.
.Net for foxheads - Blog (main)
FoxSharp - Blog (mirror)
Welcome to FoxyClasses

LinqPad - C#,VB,F#,SQL,eSQL ... scratchpad
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform