Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Using .SetAll()
Message
From
14/03/2008 11:45:59
 
 
To
14/03/2008 11:39:10
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Title:
Environment versions
Visual FoxPro:
VFP 8 SP1
Miscellaneous
Thread ID:
01302151
Message ID:
01302164
Views:
10
>I have a page with a bunch of buttons on it. It want to set the Visible property to some condition based upon a property inside the button. Something like
>WITH myForm.myPageFrame
>  loPage = .pages(.activepage)
>  WITH loPage
>       do some stuff
>       .setAll('visible',tag = 'yes','myButtonClass')
>       more stuff
>  ENDWITH
>ENDWITH
>
>However, when the setAll() line is executed I get a "Variable 'Tag' is not found" error.
>
>I also tried .tag = 'yes' but the reference would be to the page's Tag, not but button's.
>
>I've gotten around this by looping through all the buttons but it feels cleaner to do it in the one statement. Is there some way to use setAll() and reference a property inside the objects being "set"?
>
>Thanks.........Rich

What you're attempting to do is to set the Visible property to .T./.F. depending on what the variable tag is. If what you're trying to check is the .Tag property for each control, you'll have to do it in a loop, not with .SetAll().
Fred
Microsoft Visual FoxPro MVP

foxcentral.net
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform