Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Question regarding object referencing
Message
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00056749
Message ID:
00056763
Views:
28
>A question regarding object referencing:
>When I try to reference a form from within an external
>pgogram by using the syntax form1.pageframe1.refresh
>I get an "object not found" message, yet form1 is the
>name of my form. When I use "thisform", I get a message
>that "thisform" must be used within a method.
>How can I reference the form to make it refresh from
>my program?
>Thanks for your help.
>Spencer Fried
>sfried3@ix.netcom.com
Spencer,

In addtion to what Vladimir has todkl you, you can pass a reference to the form to the program by;

DO MyPrg WITH THISFORM

or

MyPrg(THISFORM)

Then in the prg you accept the parameter and use it to reference the form.

* MyPrg
PARAMETERS poObject

poObject.Refresh()

Thsi way the same program can be used by multiple different forms and the referencing does not get complex.
Previous
Reply
Map
View

Click here to load this message in the networking platform