Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Refferences to FormSet
Message
 
To
13/05/1998 14:50:15
General information
Forum:
Visual FoxPro
Category:
Forms & Form designer
Miscellaneous
Thread ID:
00099158
Message ID:
00099165
Views:
22
>Hello everyone!
>Here I'm experiencing a terrible situation. I have a main form and trying to run another form which is actually formset by simply pushing a command button, and click event has just a classic DO FORM mr.
>FormSet.Name is frmSetMedia has a form frmMedia. The question is ? How I can make a refference to frmMedia.txtText.Value.
>
>I was trying
>
>mr.frmMedia.txtText.value
>frmSetmedia.frmMedia.txtText.Value
>
>It does not work and gives me an error - object does not exist or something. Does anyone know what is happening?

You don't have a variable set as an object reference to the formset. If you are trying to access the textbox from another object on the same form, ThisForm.txtText.Value should work. If you are on another form in the same formset, ThisFormSet.frmMedia.txtText.Value should work. If you are on another form not contained in the formset, you should probably call the formset with the name parameter:

Do form mr name mr

This will give you a memory variable called mr that contains an object reference to the formset, so you could then do a mr.frmMedia.txtText.Value and it should work.

HTH
_________________________________
There are 2 types of people in the world:
    Those who need closure
Previous
Reply
Map
View

Click here to load this message in the networking platform