Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
To Anyone,
I'm attempting to Left Justify the contents of a single cell AND underline it's contents at the same time, followed by Right Justifying the contents of ANOTHER cell AND underlining it's contents. Both cells are within the same RANGE but at different offset's from the base of the RANGE . I thought I could use the following code - but it doesn't appear to be working properly ... Everything is LEFT justifying ... '-------------------------------------------- Sub Add_Underline_Staff_Number() ' Sheet (offset) begins at the cell 1 line below ' SHIFT_CPC_Number_Chart_BASE (Currently: cell F5) of Daily Sheet Sheets("Daily Sheet").Select Range("SHIFT_CPC_Number_Chart_BASE").Activate Range("SHIFT_CPC_Number_Chart_BASE").Offset(Range( "BODIES_MIN_DAY"), 0).Select ' Left Justify Cell's contents With Selection .HorizontalAlignment = xlLeft .VerticalAlignment = xlCenter ' Underline Cell's contents With .Font .underline = xlUnderlineStyleSingle End With End With Range("SHIFT_CPC_Number_Chart_BASE").Activate Range("SHIFT_CPC_Number_Chart_BASE").Offset(Range( "BODIES_MIN_EVE"), 0).Select ' EVES Number ' Right Justify Cell's contents With Selection .HorizontalAlignment = xlRight .VerticalAlignment = xlCenter ' Underline Cell's contents With .Font .underline = xlUnderlineStyleSingle End With End With Range("A3").Select End Sub '-------------------------------------------- Any help would be greatly appreciated, Jim Pellechi |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Excel - Golf - how to display "-2" as "2 Under" or "4"as "+4" or "4 Over" in a calculation cell | Excel Discussion (Misc queries) | |||
change "true" and "false" to "availble" and "out of stock" | Excel Worksheet Functions | |||
HELP on "left","right","find","len","substitute" functions | Excel Discussion (Misc queries) | |||
Count occurences of "1"/"0" (or"TRUE"/"FALSE") in a row w. conditions in the next | New Users to Excel | |||
Insert "-" in text "1234567890" to have a output like this"123-456-7890" | Excel Discussion (Misc queries) |