Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Have code working but need to edit to use on multiple variable length
worksheets instead of just applying the lines to a selected range. I have probably 100 sheets that all need the same formatting but the sheets do not all contain the same number of records. This will work for the selected sheets but if I don't give the ending cell I get an error. Sub Macro3() range("b4:b42,c4:c42,e4:e42,f4:f42,h4:h42,i4:i42,k 6:k42,l6:l42").Select Selection.Borders(xlDiagonalDown).LineStyle = xlNone Selection.Borders(xlDiagonalUp).LineStyle = xlNone With Selection.Borders(xlEdgeRight) .LineStyle = xlContinuous .Weight = xlThin .ColorIndex = xlAutomatic End With range("G4:G45, J4:J45").Select With Selection.Borders(xlEdgeRight) .LineStyle = xlDashDot .Weight = xlMedium .ColorIndex = xlAutomatic End With End Sub |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Edit Menu shortcut not fully working | Excel Discussion (Misc queries) | |||
Winzip and email multiple files (RondeBriuins code not working) | Excel Programming | |||
How to Create a Macro to Edit a Variable Amount of Information | New Users to Excel | |||
Edit single character within a variable | Excel Programming | |||
why is it saying sheetcnt is "variable not defined" how to do a global variable to share over multiple functions in vba for excel? | Excel Worksheet Functions |