#1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default More Help

Oh - is it possible to colour the entire row for the condition

so if column 4 = true then fomat the colour of the entire row for tha
value to orange

Is this possible and if so can i do it through conditional formatting

--
Message posted from http://www.ExcelForum.com

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 3,885
Default More Help

Hi
try the following
- select row 1
- goto Format - Conditional Format
- enter the formula
=$D1=TRUE
- chhose a format

--
Regards
Frank Kabel
Frankfurt, Germany

"skate " schrieb im Newsbeitrag
...
Oh - is it possible to colour the entire row for the condition

so if column 4 = true then fomat the colour of the entire row for

that
value to orange

Is this possible and if so can i do it through conditional

formatting?


---
Message posted from http://www.ExcelForum.com/


  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default More Help

Great - only problem is i have a total of 5 conditions and it will onl
allow me to add 3 - is there a way arround this

--
Message posted from http://www.ExcelForum.com

  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 27,285
Default More Help

select the entirerow or rows

assume you have selected rows 10:50

with A10 as the active Cell

Format
conditional Formatting

Change Cell Value is to Formula is

enter a formula like

=$D10=4

then hit the format button, patterns tab and select orange

OK out.

you enter you formula relative to the active cell. Using the $D fixes the
reference to column 4 of the appropriate row.

--
Regards,
Tom Ogilvy

"skate " wrote in message
...
Oh - is it possible to colour the entire row for the condition

so if column 4 = true then fomat the colour of the entire row for that
value to orange

Is this possible and if so can i do it through conditional formatting?


---
Message posted from http://www.ExcelForum.com/



  #5   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default More Help

I am importing the data from a sql database so i might need to select u
to 1000 cells - that currently are blank ...

--
Message posted from http://www.ExcelForum.com



  #6   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default More Help

Here is a pic of what i have got so far ...

Attachment filename: screenshot.gif
Download attachment: http://www.excelforum.com/attachment.php?postid=55990
--
Message posted from http://www.ExcelForum.com

  #7   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 3,885
Default More Help

Hi
only with VBA (using an event procedure) Is this a way to go for you?

--
Regards
Frank Kabel
Frankfurt, Germany


Great - only problem is i have a total of 5 conditions and it will
only allow me to add 3 - is there a way arround this?


---
Message posted from http://www.ExcelForum.com/

  #8   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default More Help

'START OF CODE
Private Sub Worksheet_Change(ByVal Target As Excel.Range)
Dim WatchRange As Range
Dim CellVal As Integer
If Target.Cells.Count 1 Then Exit Sub
If Target = "" Or Not IsNumeric(Target) Then Exit Sub
CellVal = Target
Set WatchRange = Range("A1:A10")

If Not Intersect(Target, WatchRange) Is Nothing Then
Select Case CellVal
Case 0 To 10
Target.Interior.ColorIndex = 5
Case 10 To 20
Target.Interior.ColorIndex = 10
Case 21 To 30
Target.Interior.ColorIndex = 6
Case 31 To 40
Target.Interior.ColorIndex = 46
Case 41 To 50
Target.Interior.ColorIndex = 45
End Select
End If
End Sub
'END OF CODE


i ffound this code as a vb workarround - would this sort of thing work

--
Message posted from http://www.ExcelForum.com

  #9   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 3,885
Default More Help

Hi
yes this is exactly what you need. To learn more about this kind of
event procedures see:
http://www.cpearson.com/excel/events.htm

--
Regards
Frank Kabel
Frankfurt, Germany


'START OF CODE
Private Sub Worksheet_Change(ByVal Target As Excel.Range)
Dim WatchRange As Range
Dim CellVal As Integer
If Target.Cells.Count 1 Then Exit Sub
If Target = "" Or Not IsNumeric(Target) Then Exit Sub
CellVal = Target
Set WatchRange = Range("A1:A10")

If Not Intersect(Target, WatchRange) Is Nothing Then
Select Case CellVal
Case 0 To 10
Target.Interior.ColorIndex = 5
Case 10 To 20
Target.Interior.ColorIndex = 10
Case 21 To 30
Target.Interior.ColorIndex = 6
Case 31 To 40
Target.Interior.ColorIndex = 46
Case 41 To 50
Target.Interior.ColorIndex = 45
End Select
End If
End Sub
'END OF CODE


i ffound this code as a vb workarround - would this sort of thing
work?


---
Message posted from http://www.ExcelForum.com/


  #10   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 27,285
Default More Help

If you are going to type in the values that would work.

If you are importing data, I don't know whether the change event would be
fired or not - I guess you would need to test it with the specific method
you are using.

--
Regards,
Tom Ogilvy

"skate " wrote in message
...
'START OF CODE
Private Sub Worksheet_Change(ByVal Target As Excel.Range)
Dim WatchRange As Range
Dim CellVal As Integer
If Target.Cells.Count 1 Then Exit Sub
If Target = "" Or Not IsNumeric(Target) Then Exit Sub
CellVal = Target
Set WatchRange = Range("A1:A10")

If Not Intersect(Target, WatchRange) Is Nothing Then
Select Case CellVal
Case 0 To 10
Target.Interior.ColorIndex = 5
Case 10 To 20
Target.Interior.ColorIndex = 10
Case 21 To 30
Target.Interior.ColorIndex = 6
Case 31 To 40
Target.Interior.ColorIndex = 46
Case 41 To 50
Target.Interior.ColorIndex = 45
End Select
End If
End Sub
'END OF CODE


i ffound this code as a vb workarround - would this sort of thing work?


---
Message posted from http://www.ExcelForum.com/



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



All times are GMT +1. The time now is 09:54 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"