Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
DynamicBackColor and This.Parent....
Message
From
03/08/1999 16:31:16
Kenneth Downs
Secure Data Software, Inc.
New York, United States
 
 
To
03/08/1999 15:20:04
General information
Forum:
Visual FoxPro
Category:
Other
Miscellaneous
Thread ID:
00249356
Message ID:
00249423
Views:
14
Mike,

Thanx for the confirmation. The conclusion apparently is that relative pathing is possible, but it skips a generation.

The other conclusion is that a value for DynamicBackColor set with a SetAll method call could contain column-specific references, as you have no way of knowing what column you are in!

>Hi Kenneth,
>
>>When assigning the DynamicBackColor for columns, This.Parent refers to the grid's parent, not the grid. Drove me crazy until I figured it out.
>>Does anyone know if MS has an opinion on this?
>
>I've never heard of this, but as far as I can tell your right. I put this code in a command button:
>
>
thisform.grid1.column1.dynamicbackcolor='iif(this.parent.name="Form1", rgb(255,0,0), rgb(0,0,255))'
You'd think it would turn Blue becase the name of the parent is Grid1, but it evaluates to true(red)! Try this:
>
>
thisform.grid1.column1.dynamicbackcolor='iif(this.relativerow>5, rgb(255,0,0), rgb(0,0,255))'
A column doesn't have a relative row prop but it doesn't bomb, but if you put in a .Parent it would.
>
>Thanks for the heads up Kenneth!
Previous
Reply
Map
View

Click here to load this message in the networking platform