Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
How to show form if it is already loaded
Message
 
To
23/01/2008 10:28:00
General information
Forum:
Visual FoxPro
Category:
Forms & Form designer
Environment versions
Visual FoxPro:
VFP 9 SP1
OS:
Windows XP SP2
Network:
Windows 2000 Server
Database:
Visual FoxPro
Miscellaneous
Thread ID:
01284403
Message ID:
01284542
Views:
16
>Let me try to explain again.
>
>I used one variable pxclick as a public and place it in the load event of the mainform(sinvoice.scx), I intialized it with .f.
>
>There is a command button on the form through which I call price verification (itempx.scx) form. If I click on command button (do form itempx) it appears if the focus is other then the textbox(Barcode field). But when the focus is move to the textbox(barcode field) and I call the (itempx.scx) it checks the routine of lost focus event of the textbox of barcode field.
>Therefore, when click on command button I initialize (pxclick with .t.) and I keep the syntax like in lost focus event of the barcode is ....
>If ! pxclick
> ...check the validity of the barcode field
> ...
>else
> do form itempx
>endif
>
>Now, I also include the syntax in the command button of the mainform(sinvoice.scx) like ..
>
>pxclick = .t.
>do form itempx
>
>Therefore, it loads the form twice one in background and one in foreground. Which I found active when I released the mainform(sinvoice.scx).
>
>I hope you got me properly.. please guide
>
>Thanks - Saif
*** Init event of the form sinvoice.scx
thisform.AddProperty([itempx], NULL)

*** Command button Click Event:
pxclick = .t.
IF ISNULL(thisform.itempx) OR;
   TYPE([thisform.itempx.Name]) == [U]
   do form itempx NAME thisform.itempx LINKED
ELSE
  thisform.itempx.Show()
ENDIF
Against Stupidity the Gods themselves Contend in Vain - Johann Christoph Friedrich von Schiller
The only thing normal about database guys is their tables.
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform