Changing a control's property using VBA

C

Charles

I have a calculated control that sometimes results in a negative value. If
the value is negative, I would like to change the text color from black (0)
to Red (255). Any ideas on how to do this using VBA? Also, on what "Event"
do I perform the code?

Thank You

Charles
 
C

Charles

Thanks Al

Well that was easy, but how do I need to include the "Currency" format as
well?





Al Camp said:
Charles,
Format the field with...
+#[Black];-#[Red]
--
hth
Al Camp
Candia Computer Consulting - Candia NH
http://home.comcast.net/~cccsolutions

Charles said:
I have a calculated control that sometimes results in a negative value. If
the value is negative, I would like to change the text color from black (0)
to Red (255). Any ideas on how to do this using VBA? Also, on what "Event"
do I perform the code?

Thank You

Charles
 
A

Al Camp

Charles,
$ #.00[Black],-$ #.00[Red];.00
--
hth
Al Camp
Candia Computer Consulting - Candia NH
http://home.comcast.net/~cccsolutions

Charles said:
Thanks Al

Well that was easy, but how do I need to include the "Currency" format as
well?





Al Camp said:
Charles,
Format the field with...
+#[Black];-#[Red]
--
hth
Al Camp
Candia Computer Consulting - Candia NH
http://home.comcast.net/~cccsolutions

Charles said:
I have a calculated control that sometimes results in a negative value. If
the value is negative, I would like to change the text color from black (0)
to Red (255). Any ideas on how to do this using VBA? Also, on what "Event"
do I perform the code?

Thank You

Charles
 

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