Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Event Processing Basic Query...
Message
From
02/07/1999 05:22:02
 
 
To
01/07/1999 08:23:37
General information
Forum:
Visual FoxPro
Category:
Other
Miscellaneous
Thread ID:
00236220
Message ID:
00236838
Views:
10
A number of you replied to my plea for insight into the world of event processing. Collectively you have nudged my vfp IQ up a few points, for which much gratitude. I'm still not totally clear but we're getting there...

Craig Berntson wrote:
>
It requires Modal when you call it from the "Add address now" dialog because you want to stop processing in the first form. That's the definition of Modal..."stop other processing until this form is dismissed"
>
the problem I have with that is that I still don't understand the difference in my requirements. I need the 'stop other processing' in both situations. I get it in one, but not the other.

from erik moore
>
If I understand what is happening correctly, then it seems everything is behaving as it should. Leaving the Address form modeless causees the calling procedure to continue processing before the user closes the address form...
>

in which case, why doesn't it continue processing when we invoke it with 'alt a'?

>
In situations like these, I just always leave the address form modal. Why not? Just make sure you give the user a cancel button as well as a save.
>

because we also need the option to go elsewhere from the address form (eg the Diary and Sales History) and return to it in the same way...

[From: Marcia Akins To: Harry Stottle]

>I do not understand why it works Modeless in one situation and requires Modal status in the next.
>
This is because variables are scoped to the current method or procedure.
>

Here I'm sure you're getting to the core of the problem but I just aint getting it. The calling of the form doesn't depend on the value of any variable in either situation.

>
When you say that it works when your address form is called from a hot key, where is the hot key defined? Is it defined in an OKL?
>

yes. Is this significant?

>
When you instantiate the address form in the click method of a button, the form reference goes out of scope when the click method ends.
>

that's not the situation I'm dealing with here as the form is called either using the OKL or is called from the valid method on the calling form. However, I'm sure I will have cause to use click methods to call forms, so this comment is useful. Trouble is I don't understand what is meant by the phrase
"the form reference goes out of scope when the click method ends."

Surely if you call a form from a click method, it would run the form, let you do (whatever) in that form, release the form and leave you back where you started. If not - why not?

Dragan Nedeljkovic wrote:
>
You can change the type (modal/modeless) when you call the form's show(1) method. Usual trick is to do this:

do form address name oFrmAddres NOSHOW
* this will run it modal:
oFrmAddress.Show(1)
rele oFrmAddress
>

which looks like a neat trick I can play with. Seeing what effects minor variations on that theme may have will, hopefully, illuminate some of the other mysteries of the event model.

Thanks to one and all

Harry
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform