Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Hello again, I am trying to format a worksheet by running a macro. Here are
some of my problem areas that I would like to condense if possible. Example 1 Is a partial list of about 25 items that need to be added: Range("H19").Select ActiveCell.FormulaR1C1 = "Duty Groups" Range("S19").Select ActiveCell.FormulaR1C1 = "Hours" Range("Y19").Select ActiveCell.FormulaR1C1 = "Codes" Range("E21").Select ActiveCell.FormulaR1C1 = "Memorial Day" Range("E22").Select ActiveCell.FormulaR1C1 = "Labor Day" Range("E23").Select ActiveCell.FormulaR1C1 = "Christmas(December 25th)" Range("K21").Select ActiveCell.FormulaR1C1 = "New Years Day(Jan 1st)" Range("K22").Select ActiveCell.FormulaR1C1 = "Independance Day(July 4th)" Range("K23").Select ActiveCell.FormulaR1C1 = "Thanksgiving(4th Thursday in Nov)" Example 2 Is a partial list of about 15 employees,their shift code and hours code: Range("A4").Select ActiveCell.FormulaR1C1 = "Smith" Range("B4").Select ActiveCell.FormulaR1C1 = "97632" Range("C4").Select ActiveCell.FormulaR1C1 = "A" Range("D4").Select ActiveCell.FormulaR1C1 = "1" Range("A5").Select ActiveCell.FormulaR1C1 = "Pearson" Range("B5").Select ActiveCell.FormulaR1C1 = "95883" Range("C5").Select ActiveCell.FormulaR1C1 = "B" Range("D5").Select ActiveCell.FormulaR1C1 = "1" Range("A6").Select ActiveCell.FormulaR1C1 = "Gonzales" Range("B6").Select ActiveCell.FormulaR1C1 = "268603" Range("C6").Select ActiveCell.FormulaR1C1 = "B" Range("D6").Select ActiveCell.FormulaR1C1 = "2" Any thoughts on this??? |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Can I shorten this any? | Excel Worksheet Functions | |||
Shorten code to apply to all sheets except a few, instead of individually naming them, and later adding to code. | Excel Programming | |||
Any way to shorten this up? | Excel Worksheet Functions | |||
Shorten Code for repeated function use | Excel Programming | |||
Shorten Code? | Excel Programming |