Information générale
Catégorie:
Gestionnaire d'écran & Écrans
I have a form which is called using DO FORM MyForm WITH param1,param2 TO lcResultString. If param2='VALIDATE' I wish to validate param1 only and not place the form in interactive mode. The Init() code is something like this...
IF param2='VALIDATE'
form.ReturnProperty = Validate(param1) && returns success value
RETURN .F. && form is not displayed and execution moves to form.Unload()
ELSE
Form displays in interactive mode.
ENDIF
When the form is in interactive mode, a character string is returned and everything is fine. However, if Init() returns .F., lcResultString in the above DO FORM command is always .F., no matter what the value of form.ReturnProperty is. I have traced code execution and form.ReturnProperty has the correct value (eg. 'VALID') right up to the RETURN line of the Unload() event.
Has anyone any idea how to overcome this problem? In case it is relevant, I am using VFP9 SP1. The form is definitely modal.
Any help would be appreciated.
Alan
Suivant
Répondre
Voir le fil de ce thread
Voir le fil de ce thread à partir de ce message seulement
Voir tous les messages de ce thread
Voir tous les messages de ce thread à partir de ce message seulement