Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Problem with save screen
Message
From
20/08/2004 13:39:32
 
 
To
20/08/2004 00:10:16
General information
Forum:
Visual FoxPro
Category:
Other
Miscellaneous
Thread ID:
00931678
Message ID:
00934958
Views:
15
>Dear Sir,
>
>Please write some codes to according to your advice.
>I shall be very thankful to you.
>
>Thanks in advance

In your first form's button that calls the second form:
DO FORM f2 WITH thisform
In your second form, you need code in 2 places. You need to have the oCallingForm property added in the designer, or you can have a line of code like thisform.AddProperty("oCallingForm") if you're using VFP6 or above. You need code in the Init:
LPARAMETERS toCallingForm
thisform.oCallingForm = toCallingForm
thisform.oCallingForm.Visible = .f.
and in the Unload:
thisform.oCallingForm.Visible = .t.
No timers involved, and the focus is still on form 1 button that called form 2 when you return.

Or, another way to achieve the same effect without needing to pass a parameter to the second form (this code goes in form2.Load):
thisform.oCallingForm = _SCREEN.ActiveForm
thisform.oCallingForm.Visible = .f.
You still need the oCallingForm property and the code in the Unload.

Or, if you don't really need to hide the first form, you can just make your second form modal.
Fred
Microsoft Visual FoxPro MVP

foxcentral.net
Previous
Reply
Map
View

Click here to load this message in the networking platform