Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
Discussion GroupsFormsForms ProgrammingQueriesModules / DAO / VBAReports / PrintingMacrosDatabase DesignSecurityConversionImporting / LinkingSQL Server / ADPMultiuser / NetworkingReplicationSetup / ConfigurationDeveloper ToolkitsActiveX ControlsNew UsersGeneral 1General 2
Access DirectoryToolsTutorialsUser Groups
Related Topics
SQL ServerOther DB ProductsMS OfficeMore Topics ...

MS Access Forum / Forms / April 2008

Tip: Looking for answers? Try searching our database.

Conditional Formatting-HELP anyone?!

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Adam - 17 Apr 2008 16:56 GMT
I'm trying to set a conditional format on a field that will become disabled
based on the value of another field (which is a drop-down combo box). I'm
choosing the "Expression Is" in the condition set up box and have tried the
following expressions:
[CobmoBox]![Exercise]="No Exercise Today"
[Exercise]="No Exercise Today"
[Forms]![Exercise]="No Exercise Today"
[Forms]![CobmoBox]![Exercise]="No Exercise Today"

and none of them work - IS my expression wrong??
Klatuu - 17 Apr 2008 17:09 GMT
Assuming [Exercise] is the name combo box you want to use to enable or
disable a different control, select the control you want to disable if the
value is "No Exercise Today'.

Select Expression Is
Then in the Expression box put
[Exercise]="No Exercise Today"

Then click the Enable/Disable button and it should grey out.  Now, when the
combo box names [Exercise] contains the value "No Exercise Today", the
control you selected when you entered the statement should be disabled.
Signature

Dave Hargis, Microsoft Access MVP

> I'm trying to set a conditional format on a field that will become disabled
> based on the value of another field (which is a drop-down combo box). I'm
[quoted text clipped - 6 lines]
>
> and none of them work - IS my expression wrong??
Ron2006 - 17 Apr 2008 21:53 GMT
If what Dave said does not seem to work,  What is the "Name" (in the
name property on the other tab of the field properties)?

That is what should be in the [] of the selection.

Ron
Klatuu - 17 Apr 2008 22:30 GMT
That is what I tried tp say.
But, that makes it more clear.
Signature

Dave Hargis, Microsoft Access MVP

> If what Dave said does not seem to work,  What is the "Name" (in the
> name property on the other tab of the field properties)?
>
> That is what should be in the [] of the selection.
>
> Ron
Adam - 18 Apr 2008 02:23 GMT
I tried this but it still does not work. I get no errors but it just wont
change. I tried seeing if maybe it only takes place with any newly created
records but didnt work. Any other ideas?

> That is what I tried tp say.
> But, that makes it more clear.
[quoted text clipped - 5 lines]
> >
> > Ron
Ron2006 - 18 Apr 2008 13:01 GMT
Is the combobox bound to a field?

Is what is stored in the field actually   "No Exercise Today"  or is
it storing instead an ID number of the record that is the basis for
the combobox?

If that is the case then you will have to test for the value of the ID
that corresponds to "No Exercise Today"

Ron
Adam - 21 Apr 2008 16:02 GMT
This worked! It was based on a look up table and stored by ID and displaying
the filed value. THANKS!!

> Is the combobox bound to a field?
>
[quoted text clipped - 6 lines]
>
> Ron
Ron2006 - 18 Apr 2008 13:11 GMT
I tried a post earlier but it did not seem to show up so I will try
again.

Is the combobox bound to a field?
Is the value that is stored in that bound field "No Exercise Today" or
is it storing the id or key of that entry?

If it is actually storing the ID then you will have to test for the
value of the ID that corresponds with "No Exercise Today"

Ron
Klatuu - 18 Apr 2008 14:31 GMT
Ron has a good point.  If your combo is a multi column combo and the text
being displayed is not the bound column, it will not work that way.  You will
need to use the value of the bound column that relates to the text being
displayed.

I know the concept works, because I tested it before I answered your question.
Signature

Dave Hargis, Microsoft Access MVP

> I tried this but it still does not work. I get no errors but it just wont
> change. I tried seeing if maybe it only takes place with any newly created
[quoted text clipped - 9 lines]
> > >
> > > Ron
Ron2006 - 18 Apr 2008 13:25 GMT
I have tried 3 times to post a reply it does not seem to want to keep
my reply
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.