473,408 Members | 1,821 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,408 software developers and data experts.

Conditional Format Based on a Different Cell

I am trying to conditionally format an unbound field in an access form
based on the value in another access field. The unbound field is
actually the background to the form. I want users to be aware of the
status of the case that they are working on. For example, if the
status field is "Closed", I want the unbound field (background of
detail section) to be red. If it is "Inactive", I want the unbound
field to be yellow. If it is anything else, I want it white. I have
tried this numerous ways and have searched through postings. I hope
someone can help.

Thanks,
Carolyn
Nov 13 '05 #1
1 2283
On 23 Jun 2004 12:59:57 -0700, Carolyn wrote:
I am trying to conditionally format an unbound field in an access form
based on the value in another access field. The unbound field is
actually the background to the form. I want users to be aware of the
status of the case that they are working on. For example, if the
status field is "Closed", I want the unbound field (background of
detail section) to be red. If it is "Inactive", I want the unbound
field to be yellow. If it is anything else, I want it white. I have
tried this numerous ways and have searched through postings. I hope
someone can help.

Thanks,
Carolyn


This will be on Single Form view only.

You do not need an unbound form for this.
You can change the detail back color directly.

Place the following code in both the form's Current event, and in the
[Status] AfterUpdate event:

If [Status] = "Closed" Then
Me.Section(0).BackColor = vbRed
ElseIf [Status] = "Inactive" Then
Me.Section(0).BackColor = vbYellow
Else
Me.Section(0).BackColor = vbWhite
End If

--
Fred
Please only reply to this newsgroup.
I do not reply to personal email.
Nov 13 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

4
by: TheKeith | last post by:
I just wrote the following script for something I'm working on: ---------------------------------------------------------------------------- ------------------- <html> <head> <script...
3
by: Jouke Langhout | last post by:
Hello all! For quite some time now, I've got the following problem: Access won't close properly when a user closes the application. An ACCESS process stays active and that process can only be...
1
by: John | last post by:
My report is based off of a table. I need a record on the report to be highlighted if that record ID is in a different table. Something like, if record ID exists in Query X, then conditional format...
5
by: Andrew Chanter | last post by:
Does anyone know a way you can use conditional formatting to create a banded style view as is commonly seen on the internet. (In othe words the first record appears on a gray background, the 2nd...
6
by: Marc Jennings | last post by:
Hi there, I am trying to get some conditional functionality into some of my apps. I can use the format : private void doStuff() { //do something }
2
by: DraguVaso | last post by:
Hi, I'm looking for a nice way to format the cell of my datagrid according to some predefined 'rules'. I found a lot on the site of George shepherd, but it wasn't really what I was looking for:...
4
by: Doug Bell | last post by:
Hi, I needed to make a TextBox on a DataGrid ReadOnly based on the condition of another cell on its row. I achieved this using a Custom Data Column Class "DacDGTextColLotNo" but I can't get the...
0
by: NDK | last post by:
Ok so I have an html page with an embedded excel object. I load some information into the object from a spreadsheet. (works perfectly) I would like to be able to change the background of a few...
10
by: afromanam | last post by:
Regards, Please help What I'm trying to do is this: (and I can't use reports since I must export to Excel) I export some queries to different tabs in an excel workbook I then loop through...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.