Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Get Object Reference to Form Control
Message
From
10/09/2004 14:14:21
 
 
To
All
General information
Forum:
Visual FoxPro
Category:
Forms & Form designer
Title:
Get Object Reference to Form Control
Miscellaneous
Thread ID:
00941146
Message ID:
00941146
Views:
69
VFP5

I have some checkbox controls in a Container-based Business Object. They are numbered sequentially Check1, Check2, etc.

I need to process these sequentially and enable or disable them appropriately. I'd like to use a FOR loop but the method I'm using to get an object reference to each checkbox seems kludgy. Can anyone see a better way?
LOCAL ;
  lcCheckBoxName, ;
  loCheckBox

FOR lnIx = 1 TO SomeNumber STEP 1
  lcCheckBoxName = "This.Check" + LTRIM(STR(lnIx))
  loCheckBox = &lcCheckBoxName
  * Name expression or EVALUATE() don't work in above line

ENDFOR
Regards. Al

"Violence is the last refuge of the incompetent." -- Isaac Asimov
"Never let your sense of morals prevent you from doing what is right." -- Isaac Asimov

Neither a despot, nor a doormat, be

Every app wants to be a database app when it grows up
Next
Reply
Map
View

Click here to load this message in the networking platform