Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Interactive Messageboxes
Message
From
05/08/2000 23:12:27
 
 
To
05/08/2000 22:59:19
General information
Forum:
Visual FoxPro
Category:
Forms & Form designer
Miscellaneous
Thread ID:
00401589
Message ID:
00401616
Views:
22
One follow up to this:
In order to use DO FORM, the form must be an SCX, not a class.
If you prefer using form classes, you can do this instead.
Messageform is still a modal form, and still has a custom cRetVal property.
Instead of Releasing the form, Hide it
The Unload() event would no longer have any code.
** CallingForm.cmdAppend.Click()
LOCAL loMessageForm, lcValue
loMessageForm = NEWOBJECT("messageform", "messageform_lib")
** since it won't get returned, you'll have to grab it
lcValue = loMessageForm.cRetVal
IF NOT EMPTY(lcValue) AND VARTYPE(lcValue)="C"
  thisform.txtTarget.Value = lcValue
  ** do append code
ELSE
  ** some other cute messagebox :)
  ** don't do append
ENDIF


** messageform.cmdOK.Click()
thisform.cRetVal = ALLTRIM(thisform.txtMessage.Value)
thisform.Hide()

** messageform.cmdCancel.Click()
thisform.cRetVal = ALLTRIM(thisform.txtMessage.Value)
thisform.Hide()
Insanity: Doing the same thing over and over and expecting different results.
Previous
Reply
Map
View

Click here to load this message in the networking platform