Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Dynamic grid-column button caption
Message
 
To
21/03/2009 00:55:26
Alan Harris-Reid
Baseline Data Services
Devon, United Kingdom
General information
Forum:
Visual FoxPro
Category:
Forms & Form designer
Environment versions
Visual FoxPro:
VFP 9 SP1
Miscellaneous
Thread ID:
01390208
Message ID:
01390266
Views:
69
>Hi there,
>
>I have a grid with a column that contains a command-button with a caption dependent on data relating to the corresponding row. There are too many values to contstruct separate buttons (each called via. the DynamicCurrentControl) property, so I was wondering what is the best way to have variable button caption text?
>
>Alternatively, what is the best way to make a textbox look like a command-button? I have set a grey background, arrow pointer and 3d mouse-over effect, but it still doesn't quite look like a normal command button.
>
>Any ideas would be appreciated.
>
>Alan

If you keep caption text in some field you could try something like this:
**** Init of the form:
thisform.Grid1.ColumnWithButton.DynamicBackColor = "thisform.ChangeButtonCaption()"

**** Form.ChangeButtonCaption method
thisform.Grid1.ColumnWithButton.Button1.Caption = ALLTRIM(Table.Field)
RETURN thisform.Grid1.ColumnWithButton.BackColor
NOT TESTED!
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