Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Count textbox
Message
 
To
02/06/2005 05:15:05
General information
Forum:
Visual FoxPro
Category:
Forms & Form designer
Title:
Environment versions
Visual FoxPro:
VFP 8
Database:
Visual FoxPro
Miscellaneous
Thread ID:
01019278
Message ID:
01019282
Views:
19
>hi all,
>
>i need help to count how many textbox.visible .t. at my form as anumber
>m.count1=3 or 2 or ...
>
>thisform.text4.visible =Thisform.text4.value>0
>thisform.text5.visible=Thisform.text5.value>0
>thisform.text6.visible=Thisform.text6.value>0
>thisform.text7.visible=Thisform.text7.value>0
>thisform.text8.visible=Thisform.text8.value>0
>thisform.text9.visible=Thisform.text9.value>0
>
>thanks
nTxtVisible = 0
FOR i = 1 TO thisform.ControlCount
    oCtrl =  thisform.Controls(i)
    IF UPPER(oCtrl.BaseClass) == "TEXTBOX"
       nTxtVisible = nTxtVisible + IIF(oCtrl.Visible,1,0)
    ENDIF
ENDFOR
WAIT WINDOW nTxtVisible
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