Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Does a form exist? (I'm missing something simple)
Message
 
To
30/11/2002 19:44:24
General information
Forum:
Visual FoxPro
Category:
Forms & Form designer
Miscellaneous
Thread ID:
00728422
Message ID:
00728462
Views:
12
Hi Allen, I use the _screen.forms() function. This function returns the numeric index of visible forms. I created a function that will let me know if a form is visible by using the form's name.

I hope this helps.
Kurtwood


cFormName = _Screen.Forms(FormName("form2")).Name

IF THISForm.Name = cFormName
**Form is not Active/Visible
ELSE
**Form is Active/Visible
ENDIF


*-----------------------------
FUNCTION FormName
PARAMETER xformname
nFormCount = _Screen.FormCount

FOR n = 1 TO nFormCount
nFormNumber = 1
IF UPPER(_Screen.Forms(n).name) == UPPER(xFormName)
nFormNumber = n
EXIT
ENDIF
ENDFOR
RETURN(nFormNumber)
ENDFUNC
Previous
Reply
Map
View

Click here to load this message in the networking platform