Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Jaime Z Prat Ramon
 
Posts: n/a
Default how can I extend the condictional format to nine conditions?

I need to move only the color of a cell into another cell.
  #2   Report Post  
Bob Phillips
 
Posts: n/a
Default

Private Sub Worksheet_Change(ByVal Target As Range)

On Error GoTo ws_exit:
Application.EnableEvents = False
If Not Intersect(Target, Me.Range("A1:H10")) Is Nothing Then
With Target
Select Case .Value
Case 1: .Interior.ColorIndex = 3
Case 2: .Interior.ColorIndex = 5
Case 3: .Interior.ColorIndex = 10
'etc.
End Select
End With
End If

ws_exit:
Application.EnableEvents = True
End Sub

'This is worksheet event code, which means that it needs to be
'placed in the appropriate worksheet code module, not a standard
'code module. To do this, right-click on the sheet tab, select
'the View Code option from the menu, and paste the code in.




--
HTH

Bob Phillips

"Jaime Z Prat Ramon" <Jaime Z Prat wrote in
message ...
I need to move only the color of a cell into another cell.



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
Why does my format keep changing in the cell? Denise Excel Discussion (Misc queries) 0 August 30th 05 04:23 PM
Copy cell format to cell on another worksht and update automatical kevinm Excel Worksheet Functions 21 May 19th 05 11:07 AM
Conditonal Format with a date format Kevin Excel Discussion (Misc queries) 2 April 27th 05 10:20 PM
Keep custom format in new worksheet Buddy Excel Discussion (Misc queries) 2 March 14th 05 10:03 AM
Extend data range format and formulas Larry F Excel Worksheet Functions 4 February 2nd 05 06:46 AM


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