none
VBA code worked fine until I moved it to a button RRS feed

  • Question

  • I had Excel vba code that was working fine. I want to make it work with a button.  I added the button. I then added a call in the button code to the sub that was in the Macro developer window but nothing happened (code did not execute but got no error). So I cut and pasted the code in the button code window. Now the code is executing but I am getting an error (Run-Time error '1004' Application -defend or object defined error)

    the error is occurring when it is executing

    Range("h15").Select

    Like I said earlier all my code worked fine until I copied it to the button code window.

    AZ

    Thursday, January 28, 2016 4:16 PM

All replies

  • Hi AZCowboy602,

    I suppose you should make it clear about "Range", such as
    Worksheets("Sheet1").Range().Select

    Regards.
    Friday, January 29, 2016 5:27 AM