Thread: Offset Code
View Single Post
  #3   Report Post  
Posted to microsoft.public.excel.programming
Dave Peterson[_3_] Dave Peterson[_3_] is offline
external usenet poster
 
Posts: 2,824
Default Offset Code

How about .resize:

cells(il,"n").resize(1,4).delete shift:=xlshiftup

or not quite as pretty:

range(cells(il,"N"),cells(il,"n").offset(0,3)).del ete shift:=xlshiftup


Todd Huttenstine wrote:

I have the following code that deletes a certain cell...

Cells(i1, "N").Delete Shift:=xlShiftUp

I would like it to also delete the next 4 cells to the
right using the same delete method? I would assume I
would have to use an offset method. Can anyone please
tell me how to do this?

Thank you

Todd Huttenstine


--

Dave Peterson