Copying Color Index + conditional Formats + validation

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I have the following working:

With aWS.Cells(r.Row, r.Column)
.Value = oWS.Cells(r.Row, r.Column).Value
.Locked = oWS.Cells(r.Row, r.Column).Locked
'.Font.Interior.ColorIndex =
oWS.Cells(r.Row,r.Column).Font.InteriorColor.Index
end with

I want to copy the background color index, the conditional format and the
cell validation from oWS to aWS. Can someone assist?
 
the best way of learning how to do this is recording a macro when you
manually perform the operation. Here is the code I got. the differnce
between you code and mine is "Font"

Sub Macro2()
'
' Macro2 Macro
' Macro recorded 2/19/2007 by Joel Warburg
'

'
Range("D17:F23").Select
With Selection.Interior
.ColorIndex = 42
.Pattern = xlSolid
End With
Range("H18").Select
End Sub
 
I tried recording it and it didn't work. That's why I tried the font. Any
other suggestions?
 
oWS.Cells(r.Row, r.Column).Copy
With aws.Cells(r.Row, r.Column)
.PasteSpecial Paste:=xlPasteFormats
.PasteSpecial Paste:=xlPasteValues
.Locked = oWS.Cells(r.Row, r.Column).Locked
End With



--
---
HTH

Bob

(there's no email, no snail mail, but somewhere should be gmail in my addy)
 
Back
Top