By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
424,495 Members | 994 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 424,495 IT Pros & Developers. It's quick & easy.

Continuous Form Colour

P: n/a
Hi,

I have read several postings about changing the colour of text for
certain textboxes on a continuous forms. I however am unable to get
this to work for what I am trying to do. When I put in my code for
the control source I get the #Error showing up in the text boxes.
What I have in the control source for the text box is:
=iif(HotDeadLine=-1,nextActionDate,"") HotDeadLine is from a table
and nextActionDate is also from the same table. If I change
nextActionDate to something in quotes or change it HotDeadLine it
displays a value and not the #Error. So I assume you can't reference
2 different field names from tables... Does anyone know what I can do
to get this to work. What I need is any nextActionDates that have a
HotDeadLine value of -1 to be displayed in red otherwise the
nextActionDate will just be displayed in the usual black. If it
helps I am using Access from the Office XP Suite.

Thanks in advance for your hepl!

Brad
Nov 13 '05 #1
Share this Question
Share on Google+
1 Reply


P: n/a
Are the two fields from the table that the form is using as its Record
Source? If so, try enclosing them in brackets. I know that for most things
you don't need to if there aren't spaces in the name, but in a control's
Control Source you need to any way.

=IIf([HotDeadLine] = -1, [nextActionDate], "")

For the color change, in form design view, right click the control and
choose Conditional Formatting. In the combo box choose Expression. Set the
Expression to

[HotDeadLine] = -1

and set the color to Red.

--
Wayne Morgan
MS Access MVP
"Brad" <cr****@hotmail.com> wrote in message
news:64**************************@posting.google.c om...
Hi,

I have read several postings about changing the colour of text for
certain textboxes on a continuous forms. I however am unable to get
this to work for what I am trying to do. When I put in my code for
the control source I get the #Error showing up in the text boxes.
What I have in the control source for the text box is:
=iif(HotDeadLine=-1,nextActionDate,"") HotDeadLine is from a table
and nextActionDate is also from the same table. If I change
nextActionDate to something in quotes or change it HotDeadLine it
displays a value and not the #Error. So I assume you can't reference
2 different field names from tables... Does anyone know what I can do
to get this to work. What I need is any nextActionDates that have a
HotDeadLine value of -1 to be displayed in red otherwise the
nextActionDate will just be displayed in the usual black. If it
helps I am using Access from the Office XP Suite.

Thanks in advance for your hepl!

Brad

Nov 13 '05 #2

This discussion thread is closed

Replies have been disabled for this discussion.