Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 3
Default Conditional Formatting Not Working Out

In a spreadsheet macro I'm building, I need to test the contents of one cell
for a value and if the value is true, set a background color for the active
cell based on whether its value is equal to or greater than a calculated
value derived from a value in another cell. I can't get this done, so far,
with using Conditional Formatting. Here is a visual of what I'm trying to
accomplish.

A B C D
1Wks in Mo. 4.2 4.2
2Name Type June July
3Fred INT 124 133
4Kay EXT 155 170

In this example, if Fred has a type of "INT" in B3 then in cell D3 I want to
first take the value of D1 x 30, which would equal 126. If Fred has a value
in D3 of greater than or equal to 126, then I want to change the background
color to Red.

I have 13 cells on each row that I need to do this type of calculation for.
I there is a per cell formula that I could use with Conditional Formatting,
that would be great. If not, is there a way to do this with VBA? (I'm sure
there is, but I don't have the bean for figuring it out!) I would really
appreciate some help with this one.
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 10,593
Default Conditional Formatting Not Working Out

=AND($B3="INT",$D3=$D$1*30)

--
HTH

Bob

(there's no email, no snail mail, but somewhere should be gmail in my addy)

"Big Red" wrote in message
...
In a spreadsheet macro I'm building, I need to test the contents of one
cell
for a value and if the value is true, set a background color for the
active
cell based on whether its value is equal to or greater than a calculated
value derived from a value in another cell. I can't get this done, so far,
with using Conditional Formatting. Here is a visual of what I'm trying to
accomplish.

A B C D
1Wks in Mo. 4.2 4.2
2Name Type June July
3Fred INT 124 133
4Kay EXT 155 170

In this example, if Fred has a type of "INT" in B3 then in cell D3 I want
to
first take the value of D1 x 30, which would equal 126. If Fred has a
value
in D3 of greater than or equal to 126, then I want to change the
background
color to Red.

I have 13 cells on each row that I need to do this type of calculation
for.
I there is a per cell formula that I could use with Conditional
Formatting,
that would be great. If not, is there a way to do this with VBA? (I'm sure
there is, but I don't have the bean for figuring it out!) I would really
appreciate some help with this one.



  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 3
Default Conditional Formatting Not Working Out

Thank you, Bob, this worked perfectly!

"Big Red" wrote:

In a spreadsheet macro I'm building, I need to test the contents of one cell
for a value and if the value is true, set a background color for the active
cell based on whether its value is equal to or greater than a calculated
value derived from a value in another cell. I can't get this done, so far,
with using Conditional Formatting. Here is a visual of what I'm trying to
accomplish.

A B C D
1Wks in Mo. 4.2 4.2
2Name Type June July
3Fred INT 124 133
4Kay EXT 155 170

In this example, if Fred has a type of "INT" in B3 then in cell D3 I want to
first take the value of D1 x 30, which would equal 126. If Fred has a value
in D3 of greater than or equal to 126, then I want to change the background
color to Red.

I have 13 cells on each row that I need to do this type of calculation for.
I there is a per cell formula that I could use with Conditional Formatting,
that would be great. If not, is there a way to do this with VBA? (I'm sure
there is, but I don't have the bean for figuring it out!) I would really
appreciate some help with this one.

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Not working: Conditional Formatting Mel[_4_] Excel Discussion (Misc queries) 6 May 3rd 23 03:42 AM
Conditional Formatting - not working Maze[_2_] Excel Discussion (Misc queries) 0 February 10th 10 07:22 PM
Conditional Formatting ROW not working Rod Excel Discussion (Misc queries) 8 October 5th 08 09:32 PM
Conditional Formatting not working Crowbar via OfficeKB.com Excel Programming 1 November 19th 05 08:08 PM
Conditional formatting not working! Simon Lloyd[_420_] Excel Programming 13 May 8th 04 05:43 PM


All times are GMT +1. The time now is 10:45 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"