Conditional Formating (If statements)

In the conditional formatting box how would I make B4 turn yellow if F12 is 
between 10 and 15?
4/6/2010 6:26:26 PM
excel.programming 6508 articles. 2 followers. Follow

4 Replies

Similar Articles

[PageSpeed] 1

Right-click Sheet, click 'View Code', and paste this into the window that 

Private Sub Worksheet_Change(ByVal Target As Range)
Dim rnArea As Range
Dim rnCell As Range

     With rnCell
        If Range("F12").Value >= 10 And Range("F12").Value <= 15 Then

             Range("B4").Interior.ColorIndex = 6
             Else: Range("B4").Interior.ColorIndex = 0

       End If
   End With
End Sub

If this information was helpful, please indicate this by clicking ''Yes''.

"Marc" wrote:

> In the conditional formatting box how would I make B4 turn yellow if F12 is 
> between 10 and 15?
4/6/2010 7:11:01 PM
Select B4 and CF>Use a formula

=AND(F12>10,F4<15)  taking your "between" literally.

Maybe you meant


Gord Dibben  MS Excel MVP

On Tue, 6 Apr 2010 11:26:26 -0700, Marc <>

>In the conditional formatting box how would I make B4 turn yellow if F12 is 
>between 10 and 15?

4/6/2010 7:29:01 PM
"Marc" <> wrote in message
> In the conditional formatting box how would I make B4 turn yellow if F12 
> is
> between 10 and 15?

select cell B4
Select from menus
conditional formatting

from drop down in popup select Formula Is

put in condition


Select desired format.

When I did this it did not work until I had put something into B4. I could 
then remove it and it still worked.
Maybe a small bug in excel.

4/6/2010 7:33:10 PM

In B4 I'd put =IF(OR(F12<10,F12>15),"",F12)
colour the font yellow to match the background if you don't want to see a
number in B4

In Format/Conditional Formatting
Cell Value is Between 10 and 15
Click the format tab, select patterns and choose a yellow colour.

"Marc" <> wrote in message
> In the conditional formatting box how would I make B4 turn yellow if F12
> between 10 and 15?

4/6/2010 7:36:20 PM

Similar Artilces:

Custom formatting #7
How can I do the following custom formatting – I need trailing dots before the number ……..1,234.00 Thanks for any help Right Click > Format Cells > Select Custom Enter "........ "0.00 "John Knoke" <> wrote in message > > How can I do the following custom formatting - > I need trailing dots before the number > ....1,234.00 > > Thanks for any help > > John, Use a custom number format of *.#,###.00 Note the period between the * and the f...

if and and statements
Looking for help with a 2 x 4 matrix with the following conditions A1 B1 C1 Answer 3 0 1 A1*4+2 3 0 2 0 3 1 1 A1*2+1 3 1 2 0 =IF(AND(B1=0,C1=1),+A1*4*2,IF(AND(B1=0,C...

Creating conditional clause in a module
I am in the process of writing module using vba in ACCESS 2003 which imports forecasted financial data from a particular excel file based on three inputs. I am trying to include an "error check" that will end the process if the three inputs do not match specific data in the excel file. I'm not sure how to go about doing this. Do you have any ideas what the best way to do this would be? Below is the code I have for the import part so far if that is helpful. Sub Test1() Dim ImportDir As String Dim Forecast As String Dim Version As String Dim Country As Stri...

Convert time stored as decimalised number to time format
Hello How can I convert 3.5 hours to 3:30:00? -- Emma Emma A1/24 and formate as time Mike Rogers "Emma" wrote: > Hello > How can I convert 3.5 hours to 3:30:00? > -- > Emma ...

Keeping the format but update the data
I have a report I run everyday. I want to update the data, but keep the column sizes and formatting. Any suggestions? Anybody suggest a good ebook to become more formuliar with excel? JoeM JoeM, this could be as simple as recording a macro during the formatting of the sheet after importing the data once. Then each day, after importing the new data, you simply run that macro. As for online eBook's for Excel, I'm not actually aware of any although I suspect a Google search would turn up several. It's hard to beat the "For Dummies..." series of hardcopy...

NEED HELP-wrong formatting saved ??
After using word 2007 and saving a word file, it changed the formatting from the previous file (i think it was .wps microsoft works word processor) and now its all messed up.....I think I saved it in some other wrong encoding, whenever I open this file now half of it is in some weird looking unreadable this with wha捬屨捦ㅳ尠晡‰汜牴档晜獣‰歜牥楮杮尰扤档慜㍦㔱㔰楜獮獲摩㌱ㄳ〶‷਍灜牡素筽⩜灜獮捥癬ㅬ灜畮牣屭湰瑳牡ㅴ灜楮摮湥㝴〲灜桮湡⁧屻湰硴慴ges! That is what seems to happen once the system breaks its laws from the inside. ......couldnt find online solutions...does anyone have any suggestions or s...

Conditional Formating: linking to display another cell
Hello, I am trying to make a traffic light with symbols and I've read to 'use a separate cell for the dropdown choices, with their resulting value linked into the formatted cell through an IF function, using the character that you want to display.' So: =IF someone enters '1' in B8, THEN display contents of $C$4 (will it display font and attributes?) =IF someone enters '2' in B8, THEN display contents of $C$5 =IF someone enters '3' in B8, THEN display contents of $C$6 But I've been reading everywhere and CF is very new to me and I need ...

Newbie Needs Help With Formatting E-Mails
Newbie Needs Help With Formatting E-Mails Hi all. I'm new to this site and would appreciate some formatting help. I created a new Word doc and copied and pasted some graphics and some simple text boxes in to it. The graphics and text boxes were created in Powerpoint by someone else. Looks fine on my screen. Before sending it out via e-mail to an Outlook e-mail group I have, I first sent myself a test message to see what it would look like on the receiving end. It looks a mess! The text boxes are all over the place, as is the text that is not in a box. Also, everything slide over to ...

2003 format in 2007?
I'm used to Outlook 2003, but I just bought a new computer and installed Outlook 2007. I view a week at a time, and I prefer the calendar format in 2003 -- it shows the whole week in two columns and I didn't have to scroll. Is there a way I can use the same format in 2007? No, unfortunately that view had to be removed to enabled calendar overlay. Try a two week view: -- Diane Poremsky [MVP - Outlook] Outlook Tips: Outlook & Exchange Solutions Center: Outlook Tips by email: mailto:dai...

formatting #2
Is the strikethrough formatting option no longer available in Publisher? Or if you need to use a strikethrough do you have to draw a line through the text? The line does not always stay in the same spot when you group and then have to paste on another page. Waggie wrote: > Is the strikethrough formatting option no longer available in > Publisher? Or if you need to use a strikethrough do you have to draw > a line through the text? The line does not always stay in the same > spot when you group and then have to paste on another page. ========================== You have the an...

Trying to get a type of video file format to open and run on my we
I created a video using Windows Movie maker and saved as .wmp file. I saved it to my computer and then inserted on my web page under Front Page 2003. Nothing! I then converted the file to avi format - still nothing! I then tried mpeg4 still nothing. The manual is next to useless on this subject. Anyone tell me what I need to do so that when a user opens up the page the video plays automatically. -- Simon Holloway Save as a .wmv and insert a suitable player into the page. For IE only, Insert->Web Component->Advanced Controls->ActiveX Control Click Next Choose Window...

Text formatted email
I am trying to email a long hyperlink path to some one that can only receive text formatted emails. When they receive the email it, the hyperlink gets converted in to 2 lines, top line is a hyperlink (path incomplete) the second line is "text" with the balance of the hyperlink path. I placed < > around the hyperlink and it still splits in to 2 lines. Is there any way to keep the full link path intact? Thanks! jvs Tiny URL to the rescue! :-) -- Robert Sparnaaij [MVP-Outlook] Tips of the month: -What do the Outlook Icons Mean? -Cr...

This is a multi-part message in MIME format. ------=_NextPart_000_0006_01C85845.4A66D4E0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Hello, I have to calculate commission on sales tax collected based on the = following criteria: 1) If sales tax collected is $11.00 or less, then the commission =3D to = the sales tax collected 2) If sales tax collected is $11.01 - $333.33, then the commission=3D = $11.00 3) If sales tax collected is more than $333.33, then commission =3D 3.3% = of the sales tax collected, with a maximum amount =3D $99...

Import data not in correct format
Import data reads: Need to do statistical anaysis on hundreds of numbers and Cell value # of Cells don't want to enter the numbers by hand. 3 1 4 2 Would like: Cell Value 3 4 4 ...

IF Statement 01-17-08
Hi, I am trying to run a query that has 4 fields: location, type, year, and cost. However I need to increase the cost for the year 2007 for 2 types. The IF statement I entered into the cost field is: TotalCost:IIF([Type]="C" Or "H" And [Year]=2007,[SumCost]/.9,[SumCost]) The issue I am having is that it is increasing the costs for all types. Is there a way to fix this or do i need a new query for C and H and then combine the 2 queries? Thanks for any help you can provide. Actually, you don't need to do it that way. Create a Where clause for the query tha...

Four Conditional Formats?
Dear all, I am attempting to set up a template for someone else to use on another machine, and wish conditional format a cell such that it has four potential formats. The first is based on an adjacent cell value, and if this is met, then it is colour 1. The remaining three, are all AND statements involving the first cell and another cell value being less than date A, less than date B or less than date C. Is this possible to do? I have limited VB knowledge, and am wary of using add-ins as the people I am sending this to to use have limited excel knowledge. Regards, Steve -- stevepain -...

Conditional Format
Hi, I want to assign a number to a certain conditional format. When the condition is true it should put a 1 in the cell and when the condition is false a zero or nothing should be assigned. Anyone? I seem to make the wrong code all the time. Thanks, Johanna Use the same test that the CF uses, and return 1 for TRUE and "" for FALSE. -- HTH Bob (there's no email, no snail mail, but somewhere should be gmail in my addy) "Jootje" <> wrote in message > Hi, > >...

my formats get pushed out when I insert columns
Hi folks, I am having trouble when inserting columns in a large data field. Whenever I insert a column at some point in the data field, th formulas within the data field adjust, or 'stretch', to accomodate th added column, however my conditional formatting gets pushed along t the right and doesn't adapt itself in the same way the formulas do. This means whenever I insert a column, the formulas remain correct bu I have to reset the conditional formatting for the entire data field. I would be extremely grateful for any advice on this situation. Best regards, melvi -- Message pos...

Dynamics CRM 4.0
Hi, I've modified the format in the system settings screen to be "English (United Kingdom)", however all dates are still appearing in US format. Even when you expand the calendar control it displays incorrectly. Numeric values are correct - showing the pound sign and correct decimal point. I've restarted IIS, made sure all SQL logins are British English and the default regional settings of the server are set to British English. Even rebooted the server but this still hasn't corrected the problem. Can anybody tell me how to resolve this please Thanks I was looking ...

Custom Formatting numbers question
I have a spreadsheet with lot of millions numbers floating around. When I make graphs out of it, there's too much zeros. I don't want to divide all the numbers per 1 million. Is there a way to custom format those numbers with a mask that would take care of that problem for me ? i.e. 7 456 890.98$ would be represented with 7,457 M$ tia Double-click the numbers on your chart. Hit the Scale tab. From the Display units drop-down, choose Millions. ******************* ~Anne Troy "Junkyard Engineer" <> wrote in messag...

Changing cell format
I have a worksheet that is populated with data exported from Access. The data in the Access table was serial numbers with an occasional (rare) alpha character. The column was formatted "Text" in Access. When I exported it to Excel, every value in this field (around 3000 entries), has an apostrophe (') inserted at the frontof the cell. Find and Replace does not see the ' How can I remove this so that I can use Fill>Series to populate the gaps in my data (there are many gaps)? Try copying the ' Access character and pasting it into the Replace menu. It could be...

Copying Conditional Format
Is it possible to copy conditional formatting that is already applied to a given cell to another cell? I know that the format is held and continuous formatting is possible, Thanks, Robin Chapple Hi Robin you can copy and paste formatting (including conditional formatting) using either the format painter (big yellow paintbrush toolbar icon) - click on the cell with the formatting, click on format painter, click on the cell where you want the formatting "painted" (double clicking on the format painter turns it on until you turn it off) or by using copy and then edit / paste specia...

Exponential number format
Version: 2008 Operating System: Mac OS X 10.6 (Snow Leopard) Processor: Intel I'm trying to write exponential formulas in excel 2008, but it doesn't recognize the symbol ^ that we use on excel for windows. <br> example: <br> Excel Windows : = 2^2 -> result: 4 <br><br>Excel Mac : = 2^2 -> result: error <br><br>When we import some sheet from windows to mac with this formula works, but when I try to create on mac not recognize. <br><br>My question is: There is any other way to use this Symbol, for this kind of formula? The sam...

Change date format in several worksheets
I have about 50 worksheets in a workbook and would like to change the date format in all. Is there a way to change all at once or must it be done worksheet by worksheet? Select first worksheet. Right-click on the tab and "select all sheets" to group them. Select data range in activesheet. CRTL + A(twice in XL 2003) will select all cells. Make your Format changes. What is done to one sheet will be done to all. DO NOT FORGET! to right-click on any tab and "ungroup" before making any other changes unless you want to change all sheets. Gord Dibben Excel MVP On Sat...

problem with a conditional max problem
-- What formula could you enter in cell E13 so that if a value is entered in cell E12, cell E13 will display the value of f(x) that corresponds to the largest tabulated x which is less than or equal to the value entered. For example, if 3 is entered in cell E12, then E13 should display the value of f(0). Brian If your tabulated x's are in a range named "tabx", one way: =f(LOOKUP(E12,tabx)) where f() is your function. In article <>, "Brian Cornejo" <> wrot...