Multiple Conditional Formats (4+) Using VBA

Oct 10, 2008

I would like to condition one cell to display various colors, based on the information in another cell. I have attached the file for an example. The cell to be conditioned is A1, and the cell that will specify its color is B3. For example, if the value of B3 is "Red Oak", A1 would be red, and if the value is "Maple", A1 would be green.

I have more than 3 of these that need to be formatted (conditional formatting limits to 3 formats), so I'm wondering if I can do an event macro to set the formatting.

View 4 Replies


ADVERTISEMENT

How To Copy Values In Multiple Cell With Conditional Formats

Mar 9, 2014

Here's my problem..

if i input 75 in cell G2, the value in A7:E7 will paste or will display in A2:E2
or
if i input 76 in cell G2, the value in A8:E8 will paste or will display in A2:E2
or
if i input 90 in cell G2, the value in A9:E9 will paste or will display in A2:E2
or
if i input 78 in cell G2, the value in A10:E10 will copy or will display in A2:E2

See my attachment.. sample prob.xlsx‎

View 4 Replies View Related

More Than 3 Conditional Formats?

Feb 12, 2009

I have a spreadsheet with a number of columns. In column D there are the following options: 2,3,4,C,T. I want to color the cell if there is data in the cell and column D contains a value.

So for cell L17, my conditional format I have =AND(D17=2,L17<>"") - - (RED), =AND(D17=3,L17<>"") - - (YELLOW), =AND(D17=4,L17<>"") - - (GREEN).

I need to color for values of C and T: but there are only 3 conditional formats permitted. Is there any way around this?

View 14 Replies View Related

7 Conditional Formats

Jul 20, 2008

I have a sheet that shows sun, mon, tue........,sat - all 7 days.

Under each day there are 3 cols so 21 in total.

Data is being entered into cells each day but as the week goes on it gets more difficult to match up the col & row, to many numbers.

What I would like is a way to highlight the whole range of cells per day in a different colour but only when data has been entered under a day, so if no data then no colour fill.

I only need 2 colours, 1 for sun, tue, thurs, sat &
1 for the remaining days.

=COUNTA($A1:$C20)>0

This works for one range as a conditional format but there aren't enough options to do the 7 days.

View 9 Replies View Related

Combining 2 Conditional Formats

Mar 12, 2007

how to combine 2 conditional formats?

I'm trying to shade every other row grey so its readable with this:

=MOD(ROW(),2)

But, at the same time, would like to highlight upcoming expiry dates with this:

=AND(A2-TODAY()>=0,A2-TODAY()<=30)

View 14 Replies View Related

Dates With Conditional Formats

Aug 19, 2009

I am trying to create an Excel spread sheet that keeps track of employees safety tickets and the dates they expire. Is there way to have a cell highlight to a color warning me 30 days prior to the due date listed?

Eg. John has first aid and expires on 11/15/2009. I'd like the cell that has this date to highlight red on 10/15/2009.

I have messed around with the conditional formatting and know how to format the cells color and font et., but I can not figure out the formula to use to get my results.

I am using Microsoft Office Excel 2003 (MS Office Standard)(SP3)

View 12 Replies View Related

Conditional Formatting, Any Way To Get More Than 3 Formats?

Apr 2, 2008

Anyone figure out how to get around the 3 format limit for conditional formatting? If so, I'd really love to hear about how you did it.

View 9 Replies View Related

Sum Based On Conditional Formats

Sep 11, 2008

I have to color direct payoffs and commissions (green and blue respectively). I have to have a running total of payoffs that have not cleared and one for commissions. I have set up conditional formatting to color the text based on the check classification (A for payoffs and C for commissions). What I am trying to do is write a formula that will count only the payoffs (green text) that do not have a cleared date. I am then trying to do the same for the commissions (blue text). these totals are needed separately so I do not need them combined.

I have tried sumif and sumproduct. I have since deleted the formulas i have written cause they did not work.

View 9 Replies View Related

Macro For More Than Three Conditional Formats

Oct 12, 2008

I use Excel 2003 and am trying to put together an automatic macro to apply five conditional formats to a range of cells. The range is H3:H21 and is unnamed. The values in the cells are derived from formulas. These are the conditional formats:

If there is a 1, the background color should be gold/44 and the font should be bolded.
If there is a 2, the background color should be gray 25%/15 and the font should be bolded.
If there is a 3, the background color should be dark yellow/12 and the font should be bolded.
If there is an e, the background color should be red/3 and the font should be bolded.
If there is a 0 (zero), the font should be white/2.

From what I understand, I need to put the code in by using the "View Code" option in the tab sub-menu.

View 10 Replies View Related

Not Paste Another Set Of Conditional Formats

Aug 4, 2009

I have a code that copies a template and pastes it into another tab. However, it is copying the conditional formatting and pasting it as well. I already have conditional formatting on the other tab and do not want it to paste another set of conditional formats because the formula's are changing between the copy and pastes.

View 9 Replies View Related

Conditional Formats Between Dates

Nov 22, 2007

i have a register with items for calibration. I have a column with a date the item is next due cal which is 3 years from date of receipt manually input by myself. say (H64) due 20/11/2010, i would like the cell to be green if todays date is below the date due, but amber if todays date is within 30 days of being due and finally red if todays date is over. i have manged green and red but cant seem to get the between right for the amber.

View 8 Replies View Related

Pasting Conditional Formats Without The Conditions

Sep 21, 2009

I have a spreadsheet containing all sorts of formulas & data in Columns A - H, and a formula copied down in Column I generates a number that drives a few conditional formats in the preceeding columns.

I'm trying to copy-paste the values and formats of Columns A - H into a new workbook with this pretty simple macro...

Range("A1:H195").Select
Selection.Copy
Workbooks.Add
Selection.PasteSpecial Paste:=xlPasteValues, Operation:=xlNone, SkipBlanks _
:=False, Transpose:=False
Selection.PasteSpecial Paste:=xlPasteFormats, Operation:=xlNone, _
SkipBlanks:=False, Transpose:=False
Selection.PasteSpecial Paste:=xlPasteColumnWidths, Operation:=xlNone, _
SkipBlanks:=False, Transpose:=False
Application.CutCopyMode = False
When the formats are pasted across it's pasting the conditional formatting, but they're not displaying correctly because Column I isn't coming over to the new workbook.

Is it possible to copy-paste the cell formats as they stand regardless of whether there's any conditional formatting behind it?

View 9 Replies View Related

Countif Based On Conditional Formats

Oct 16, 2009

I need to count the number of rows of active clients. I have set up a conditional format that when someone goes inactive dependent on the reason of inactiveness their entire row of information either gets greyed out or a red line through it. Is there a way to count the current "active" clients- or those that do not have these conditional formats applied to them. And this is also dependent on month, so that it does not show the same number each month.

View 9 Replies View Related

Formula To Count Conditional Formats

Oct 10, 2006

I'm trying to count cells affected by conditional formatting and I need help tidying up my efforts so far.

The numeric values in my table are formatted if they exceed values in corresponding columns on other tables, indexed via Hack #75. The logic for each cell runs someting like this:

if cell is numeric
if column in (E, M, X, Y)
if (value <c1 or > c2)
highlight in blue
end
else ' columns not in (E, M, X, Y)
if (value > c1 or < c2)
highlight in red
end
end
end

My attempt to put together a formula for each cell appears to work, it looks like this for cell B3:
'=AND(ISNUMBER($B3),
OR(
AND(.....................

View 9 Replies View Related

More Than 3 Conditional Formats For Formula Results

Jun 1, 2007

I have a range A1:D10 containing formulae. I want the cells to change colour depending on the formula result. Conditional Formatting will do the job but only up to three colour so I need to use VBA because I have 6 colours. For example, if the result is 1, the colour changes to blue, if the result is 2, the colour changes to green, etc

I have VBA code which will change the cell colour if I input a value, but not if the cell is relying on formula result. The formulae results are dependent on cells throughout the workbook. The formulae results can be letters or numbers, whatever is easier.

View 6 Replies View Related

Greater Than 3 Conditional Formats For Text And Numbers

Feb 29, 2008

I have been using conditional formatting for a project in Excel 2007 but as the end users are using Excel 2003, I have had to switch to the following VBA solution as my requirements exceed the standard 3 available conditions. I have looked at using custom formatting but I need to format the cell colour rather than just the font colour.

Private Sub Worksheet_Change(ByVal Target As Range)
Dim icolor As Integer
If Not Intersect(Target, Range("C19:IV384")) Is Nothing Then
Select Case Target
Case "0.5", "1", "U"
icolor = 38
Case "C", "M", "P"
icolor = 40
Case "A", "S", "D"
icolor = 36
Case "L", "UP", "C/E"
icolor = 35
Case Else
'Whatever
End Select
Target.Interior.ColorIndex = icolor
End If
End Sub

* When the macro is run on one worksheet, formatting and values are replicated simultaneously on another identical worksheet (not necessarily vice versa).

* As well as formatting cell colour when containing a value, a border should also be added with different colours for the top, bottom, left and right border.

* When the cell contains no value, the borders should return to how they were previously.

View 3 Replies View Related

Apply Conditional Formats To Cell Based On Entries In Another?

Jan 27, 2012

apply conditional formats to a cell, based on the entries in another, different cell?

View 2 Replies View Related

Conditional Formatting Text Equaling To Number Formats?

Apr 20, 2013

Conditional Formating Text equaling to Number formats:

Example:
C20 is '436.59 (its pasted as text often is must remain as text) and D20 is 436.9535

I want D20 to have only 2 decimals and turn green if it equals C20. And turn red if it doesnt equal C20.

View 1 Replies View Related

Remove Conditional Formatting Conditions, But Retain Formats

Jul 2, 2008

I am using excel 2007 - I need the extra available columns in Excel 2007 for my application.

I have a spreadsheet that has a significant amount of conditional formatting. I want to copy a range from this spreadsheet to another spreadsheet. In the new spreadsheet I want to remove the conditional formatting rules whilst retaining the actual formats those rules generated.

Format painter and "paste special - format" copies any formats as well as the conditional format rules.

Is htere a method within Excel to do this or can someone suggest a workaround?

View 3 Replies View Related

Macro And Conditional Formatting: Formats The Data That Is Pasted Into It From An Access Database

Dec 2, 2008

The macro firstly formats the data that is pasted into it from an access database, then it does some calculations to determine when 10 working days from a specific date is, and when 20 working days from the date is (these go in new columns at the end of the data). The macro will also add new columns which say "Not resolved" if there is no date in the Resolution column, "Yes" in the "10 working days met?" column if the condition is met and the same for 20 workings days in a different column. As the colouring etc takes a long time I really wanted to add as conditional formatting to the macro!

how to attach a spreadsheet here then I can show you what the outcome we want is. A point to note is that there is not a set number of rows each time we do this, and I don't just want 1 cell to be coloured - I want to specify which cells in the row are coloured depending on the results in another cell on that row.

View 2 Replies View Related

Sorting Data That Has Multiple Formats?

Jun 15, 2012

I have lists of products that I want to sort, but all the skus are in different formats, some letter, numbers, spaces, symbols and mixes of all.

Example:
01107919
CE-4128B9
RED-BRIC889
1124
14100119020-E
86TR
ECO CUP22OZ/1000
1418909888783301

I would like to organize them by the order of the numbers, letters and symbols, not the value of the numbers.

Example:
01107919
1124
14100119020-E
1418909888783301
86TR
CE-4128B9
ECO CUP22OZ/1000
RED-BRIC889

I have tried formatting and different sorting options but there's a dent in the wall and my forehead is getting bruised from all of the banging.

View 2 Replies View Related

Multiple Numerical Formats In A Single Cell?

Oct 7, 2008

In a single cell, I would like to show 2 values: a currency and a percentage. So A1 and A2 has values, say 50000 and .10 respectively (these are derived via formula, if it's of any relevance). What I ultimately want is "$50,000 and 10%". I've originally thought about adding the "$", " and ", and "%" separately, but I need the currency value to include commas.

View 2 Replies View Related

Multiple Formats Inside Single Text Box (activex)

Dec 29, 2008

I'm having trouble keeping the formatting correctly in a text box through VBA. I'm sure this is something simple, but I'm the intern that got stuck with trying to program for the break since they know I've taken classes on the subject. I've been able to figure out a lot

End goal: To have the first word of a text box larger, underlined, and bolded. Problem: It only formats it Calibri at 24 point with no special formatting as indicated in the code.

View 3 Replies View Related

Join Digits From Multiple Cells While Retaining Custom Formats

Apr 2, 2009

I have four different cell.

Cell a1 contains 6 digits
Cell a2 contains 1 digit
Cell a3 contains 6 digits
Cell a4 contains 4 digits.

Cells a3 and a4 may contain a number less than number of digits specified above but are custom formatted 000000 and 0000 respectively to ensure they have the correct number of digits. My problem is when I try to combine the four cells they lose their formatting. I have tried =A1&A2&A3&A4 and = concatenate(A1,A2,A3,A4). But both formulas loose the formatting from the individual cells.

View 7 Replies View Related

Copy Conditional Formats: Copy To The Rest Of The Column

Mar 29, 2009

I have a cell with seven conditional formatting formula rules that I now want to copy to the rest of the column. I can copy/paste special/formats one cell at a time but if I try to to this with a group of cells, (or try using the format painter), it treats the formula references as absolute, even though they aren't shown as absolute in the rules manager. Am I missing something? Using 2007.

View 4 Replies View Related

Multiple Conditional Format Using VBA

Feb 12, 2010

Need multiple conditional format for more than 3 condition. I don't know how to write code in VBA.

View 5 Replies View Related

Conditional Formatting Across Multiple Spreadsheets?

Jun 5, 2014

I'm trying to set up conditional formatting to show when an employee is both scheduled to be working for the current date, and is trained in a particular task.

I have a spreadsheet called "Training" for all of the tasks that employees can be trained in, with the employee names in each row, and the task names at the top of each column. The intersection of an employee's row with a task's column will have an "X" if the employee is trained in the task. This is the spreadsheet that I'd like to be formatted; if the employee is trained and also scheduled to be working, I'd like to the "X" to change to a different color.

There are separate spreadsheets within the same workbook for the schedule. This is a bit more complex since the since each week of the schedule has its own spreadsheet within the workbook; each spreadsheet is named for the Saturday of the week it is for, such as "06-07". I've been able to successfully have other formulas in the workbook auto-adjust to the current week's schedule by using variations on the TODAY function (something like INDIRECT("'"&(TEXT(TODAY()-MOD(WEEKDAY(TODAY(),1),7),"mm-dd"))), but I'm not sure how to incorporate this into conditional formatting. On each schedule sheet, there is a column for each day of the week and a row for each employee. The cell for a given day will contain the employee's schedule if they are scheduled, or it will be blank if they are not scheduled. So, the conditional formatting formula would just need to check to see if the appropriate cell was blank or not.

View 4 Replies View Related

Conditional Drop-Down For Multiple Lines

Jul 29, 2014

I have a list of car-dealers and licence plate numbers. f.e. data in tab 1 Supplier-Cars.jpg

In another tab (let's call this tab 2) I have to make drop-down lists, depending on the value in this drop-down the cell next to it must give the list of cars from this supplier. f.e. if I select in the first line Supplier 1, I get a drop-down list where I can select Car 1 if I select in the second line Supplier 4, I get a drop-down list where I can select Car 4, 6 or 7 etc. Because of the number of suppliers, I can not work with predefined lists where I put all the suppliers one next to the other...

have a drop-down in each line to go look for the cars depending on the supplier I selected ?

View 2 Replies View Related

Conditional Linking Between Multiple Sheets

Nov 24, 2008

Okay, now on to the question:

I have three sheets "Contacts"/Sheet 1, "Judges"/Sheet 2, "Sponsors"/Sheet 3. Row 1 and 2 have been used as headers in each of them.

I would like to be able to enter a value in A3 of Sheet 1, such as 'judge' (a number would work fine too), and have the contact information in the same row (columns B-M) copy into the next available row of Sheet 2 in columns B-M.

I don't know if a formula exists for this but if I could type anything in the formula box and have Excel be smart enough to figure out what I'm asking I'd type something like this:

"Hey Excel. Follow this formula: IF 'judge' in sheet 1, A3; THEN copy sheet 1, B3-M3 to sheet 2, B-M next available row...Then do the same thing for 'contacts' but copy into sheet 3."

View 14 Replies View Related

Conditional Sums Using Multiple Criteria

Feb 2, 2009

I've been struggling to figure out why my Conditional Sum formulas using multiple criteria keep reporting zero. I am tracking resource loads for a project which is divided into 4 parts (Iterations). I am trying to sum the total resource allocations per Iteration. see attachment!

View 9 Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved