Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Building an Object
Message
 
 
To
29/04/1998 15:39:12
Jeff Urso
Urso Technologies, Llc
Madison, Wisconsin, United States
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00095768
Message ID:
00095775
Views:
22
Jeff,

Provided that oGrid is indeed a reference to a grid.

lcItem = "oGrid." + lcColumn + "." + lcProperty
store lnValue to &lcItem

or
with oGrid
   lcItem = "." + lcColumn + "." + lcProperty
   store lnValue to &lcItem
endwith


If oGrid isn't you'll need to use it's full containership name that might be thisform.pgfMain.pagCustomer.grdCustomers.

You might want to take a look at the FOR EACH command which will let you easily iterate through a container's objects.

>My goal is to add to the reference of an object without knowing the complete name of the object to be changed.
>
>eg: a grid on a form is referenced as oGrid.
>
>I want to affect the property of oGrid.column1.width. I want to reference this through a table so I will have the following variable references:
>
> oGrid = Object
> lcColumn = 'column1'
> lcProperty = 'width'
> lnValue = 100
>
>How can I put the 3 above variables together to reference the width of column1 and change it at my discretion from within the program by changing the value of lnValue.
df (was a 10 time MVP)

df FoxPro website
FoxPro Wiki site online, editable knowledgebase
Previous
Reply
Map
View

Click here to load this message in the networking platform