command button forcolor and caption change

M

manchery

HI,
I have a form (continuous) with say 20 records. for Each
record there is a filed known as [Action] and a command
button. I would like to know how can i change the command
button color and caption as per the value in the field. I
tried with some code but it changes all buttons at a time.
anyone to assist how can i do this pls.
 
S

Steve Schapel

Manchery

I don't know of any better way than this, unfortunately... Use
Conditional Formatting. However, Conditional Formatting only applies to
textboxes, not command buttons. Therefore you need to use an unbound
textbox in place of the command button, and use a calculated expression
in its Control Source to change the "caption". With a bit of tweaking,
you can get a textbox to look "almost sort-of like" a command button.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top