simple code

G

gavmer

hello all,

i am after a simple code to delete the contents of cells D13-15
C19-J19 and then move to worksheet 'TEMP'....please.

I am also after a simple code that will do the above and also, delet
rows within a cell range on sheet 'TEMP' called 'pricing'

This is probably a simple task to most but i am as beginner as the
get!!

Thanks to all!!!!
 
J

JeffP

I am also a newbie so I'm hesitant to give any advise around thes
MVP's!
That said, unless there is some special reason you want to do this b
writing code, why don't you just record a macro. Even if you need t
add to that, it would certainly handle the requests you mentioned.

Jeff
 
J

JE McGimpsey

One way:

ActiveSheet.Range("D13:D15,C19:J19").ClearContents
Sheets("TEMP").Range("pricing").Delete Shift:=xlShiftUp
 
G

gavmer

Thanks!!!!! That was pretty much what i needed!!!!!

One prob, the range is 2 rows between 20 and 24 (so rows 21 and 22 ar
the range. Data pastes here expanding the range but when the range i
deleted, i am left with only 2 rows and no range. I would need rows 2
and 22 to remain. How is this done??????

Cheers!!!!
 
Top