Jul 10, 2001 #1 VBmim Programmer Joined Jun 25, 2001 Messages 361 Location BE I want to set the alignment of some cells to Center from Visual basic. I want to do something like this excelObj.activesheet.range("g1:i1".alignment = Center Does something like that works? Mim
I want to set the alignment of some cells to Center from Visual basic. I want to do something like this excelObj.activesheet.range("g1:i1".alignment = Center Does something like that works? Mim
Jul 10, 2001 #2 SteveR321 IS-IT--Management Joined Jul 10, 2001 Messages 8 Location US Yes, this is a very basic funtionality. This will do the trick for you: ActiveSheet.Range("g1:i1".HorizontalAlignment = xlCenter Steve Upvote 0 Downvote
Yes, this is a very basic funtionality. This will do the trick for you: ActiveSheet.Range("g1:i1".HorizontalAlignment = xlCenter Steve
Jul 11, 2001 #3 gmonk Programmer Joined Jul 11, 2001 Messages 1 Location NL Instead of .alignment=center you should use .HorizontalAlignment = xlCenter gmonk Upvote 0 Downvote