Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Change Field color after update

Status
Not open for further replies.

kptasteve

Programmer
Nov 2, 2002
43
US
I would like to have a field change color to remind the input user that the field has been updated. How is this possible with code.

Example
Form with subform
Duplicate record, the field that changes is the autonumber field. When this field is updated I would like the color background to turn green for go.

Thanks
Steve Marcum PT
programmer
 
Hi,

This will change the backcolor of the field in question. On the after update event the color will change. However, in order to show the normal color for other records that the user will scroll through with the form you must put the other bit of code in to set the backcolor to its normal color.

-set it on the "after update" event
'changes the backcolor of the field to green
Me!AutoNumberFieldName.BackColor = = 456660

On your form's "On Current" event do this:

'This makes the field show the normal color for each record
Me!AutoNumberFieldName.BackColor = 255

Note:
456660 is a green color, you will have to find your green color...
255 is a red color - you can make it black or whatever

HTH,

jbehrne If at first you don't succeed, call in an airstrike. - Murphy's Laws of Combat Operations
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top