Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 3
Default Excel VB help - checking conditionally formatting on one cell, applying it to another

I am creating a table in which we are inputting our test results and
comparing them against the standards. I have conditional formats on
the empty cells where we input our data that if it exceeds the
standards, then the cell is shaded gray and the text bold and
italicized. i wish to have it so IF there are any exceedances in the
table, then the first exceedance found in the table is displayed in the
notes section below the table with an explaination. please help!!

col.A - chemical name
col B. - standards
col C-F - blank for now, where we input our data

for example, say C12, E45, F2 all exceed their respective standards
(therefore cells are shaded/text bolded, etc due to conditional
format), i want to program cell A54, which is below my table, to
display C12 and have text beside it explaining what it means (ie:
denotes exceedance of table blah blah blah)

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 6,953
Default Excel VB help - checking conditionally formatting on one cell, app

Dim i as Long, j as Long, cell as Range
for i = 2 to 54
for j = 3 to 6
set cell = cells(i,j)
if cell.Value cells(cell.row,"B").Value then
Range("A54") = "The value in cell " & cell.Address & _
", [Value = " & cell.Value & "]," &
" exceeds the standard: " & cells(cell.row,2).Value
exit sub
end if
next j
Next i

--
Regards,
Tom Ogilvy


--
Regards,
Tom Ogilvy

" wrote:

I am creating a table in which we are inputting our test results and
comparing them against the standards. I have conditional formats on
the empty cells where we input our data that if it exceeds the
standards, then the cell is shaded gray and the text bold and
italicized. i wish to have it so IF there are any exceedances in the
table, then the first exceedance found in the table is displayed in the
notes section below the table with an explaination. please help!!

col.A - chemical name
col B. - standards
col C-F - blank for now, where we input our data

for example, say C12, E45, F2 all exceed their respective standards
(therefore cells are shaded/text bolded, etc due to conditional
format), i want to program cell A54, which is below my table, to
display C12 and have text beside it explaining what it means (ie:
denotes exceedance of table blah blah blah)


  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 3
Default Excel VB help - checking conditionally formatting on one cell, app

excellent! it works!

  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 3
Default Excel VB help - checking conditionally formatting on one cell, app

how can i get this to update itself?

right now if i change something in the table, i have to run the macro
for the 'notes' to be updated..i know theres a simple code for this!!!

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
Conditionally formatting a cell based on other cell values ian Excel Worksheet Functions 3 February 27th 10 10:27 PM
Conditionally formatting just part of a cell contents - how? Mac Excel Worksheet Functions 1 March 22nd 09 04:23 PM
Applying conditional formatting to cell based on another cell's in kdesemple Excel Discussion (Misc queries) 1 March 22nd 06 06:37 PM
Conditionally formatting highest valued cell? brett Excel Worksheet Functions 10 December 22nd 05 08:30 AM
Conditionally Formatting a Cell Floyd[_2_] Excel Programming 14 September 30th 05 02:02 AM


All times are GMT +1. The time now is 11:27 PM.

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

About Us

"It's about Microsoft Excel"