Hi,
I'm trying to change the background colour of a cell through VBA.. The cursor is positioned in the required cell and I've tried the following code:
'SELECT THE WHOLE CELL
Selection.EndKey Unit:=wdLine, Extend:=wdExtend
'CHANGE THE BACKGROUND COLOR
Selection.Cells.Shading.BackgroundPatternColor = wdColorGray30
But the following error was returned: <Object variable or with block not set!!> :-(
THNX,
JONATHAN
I'm trying to change the background colour of a cell through VBA.. The cursor is positioned in the required cell and I've tried the following code:
'SELECT THE WHOLE CELL
Selection.EndKey Unit:=wdLine, Extend:=wdExtend
'CHANGE THE BACKGROUND COLOR
Selection.Cells.Shading.BackgroundPatternColor = wdColorGray30
But the following error was returned: <Object variable or with block not set!!> :-(
THNX,
JONATHAN