Error 1004 when selecting a range

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I have the following code in a Macro and it works fine. When I copy it to a click event for command button I get a Run-time error 1004 "Select Method of Range class failed.

Sheets("SOAUDITSO").Select
Rows("2:2").Select
Range(Selection, Selection.End(xlDown)).Select
Selection.Delete Shift:=xlUp

What am I doing wrong?
 
Back
Top