Changing forecolor problem

A

azu_daioh

I tried using the forecolor property but for some reason I cannot get
this option whenever I type Me.IncAmtPaid. --> usually it gives me an
option and it only has one option "Value"

I want to change the text color when the value is > 31999 to red.

Here's the code I came up with to get the value of IncAmtPaid:
-----
varW = Nz(DLookup("[rptDate]", "Monthly Payment Info", _
"[License#] = '" & Me.[License#] & "' And [rptDate] = #" _
& xrptPrevDate & "#"), "0")

If Not varW = "0" Then
varX = Nz(DLookup("[AmtPaid]", "Monthly Payment Info", _
"[License#] = '" & Me.[License#] & "' And [rptDate] =
#" _
& xrptPrevDate & "#"), "0")
xIncAmtPaid = xAmtPaid - varX

Me.IncAmtPaid = xIncAmtPaid
Me.Refresh
End If
-------------

THe above is part of an OnClick event...I tried the code I found from
Microsoft site regarding forecolor using the Form_Current event but I
still can't get the option "Forecolor" from Me! or Me.IncAmtPaid

I can change the forecolor using the text box property but I want to
use a condition to change the color to red if the value is greater
than 31999.

Can someone direct me to where I need to research this or provide me
with an example please?

Thank you,

Sharon
 
R

Ron2006

Sitting on the field on the form and looking at the properties go to
the Other Tab. What is the name there.

That is the name that has to be used to get access to the forecolor
property.

Ron
 

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