Home |
Search |
Today's Posts |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Derrick:
You can use this code to see if the text in cell A1 is left, right or center aligned Private Sub CommandButton1_Click() Select Case Worksheets(1).Range("A1").HorizontalAlignment Case xlRight MsgBox "right" Case xlLeft MsgBox "left" Case xlCenter MsgBox "center" End Select End Sub HTH -Satish Derrick Salmon wrote: I'm trying to use Select Case to determine if a cell's text is aligned to the right or the left and check that the cell is not empty ... and am having no luck. Can someone suggest a code fragment thanks Derrick |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Case without Select Case error problem | Excel Discussion (Misc queries) | |||
End Select without Select Case, Block If without End If errors | Excel Programming | |||
HorizontalAlignment Error in Excel 97 | Excel Programming | |||
Excel Custom Function with Select Case | Excel Programming |