adding more fields to code

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Private Sub Form_Current()
‘If diverted color red.
I would like to add to fields [field2] and [field3] to this code and have it
do the same as field1
How do i do this?

If [field1] >= 0 Then
[lblBoxMsg].Visible = True
[field1].ForeColor = 255

Else

[lblBoxMsg].Visible = False
[field1].ForeColor = 0

Octet
 
Put an End If at the end of the code you provided and then begin another If
statement ending with an End If for Field2. Continue for each of the fields.

Hope this helps
 
Works Great
Thanks Jackie

Jackie L said:
Put an End If at the end of the code you provided and then begin another If
statement ending with an End If for Field2. Continue for each of the fields.

Hope this helps

Octet32 said:
Private Sub Form_Current()
‘If diverted color red.
I would like to add to fields [field2] and [field3] to this code and have it
do the same as field1
How do i do this?

If [field1] >= 0 Then
[lblBoxMsg].Visible = True
[field1].ForeColor = 255

Else

[lblBoxMsg].Visible = False
[field1].ForeColor = 0

Octet
 
Back
Top