deleting a range
Hi,
You don't say how your setting target.row or maxcol and I think you may mean
activecell.row instead of target .row, try this
maxcol = 5
Sheets("a lap").Range(Sheets("a lap").Cells(ActiveCell.Row, maxcol + 4),
Sheets("a lap").Cells(ActiveCell.Row, 256)).ClearContents
Note I've manually set maxcol.
Mike
"NDBC" wrote:
Could you please tel me why this wouldn't work
Sheets("a lap").Range(Cells(Target.Row, MaxCol + 4), Cells(Target.Row, _
256)).ClearContents
I'm running it from some code in a sheet called A grade if that makes a
difference.
Maxcol is dim as integer.
Thanks
|