How to pause a macro to allow user to select cell

  • Thread starter Thread starter Ron Berns
  • Start date Start date
R

Ron Berns

I am learning to do Macros in Excel and I am unable to figure this problem out.
I am using Excel 2003.

I have two spreadsheets in the same workbook. One is named Working the other is Existing.
I would like to create a macro that allows the user to copy a row from the Existing sheet to the Working sheet. I don't have a problem copying information from one sheet to another. The problem I have is allowing the user to look through the information
in the Existing sheet, select a cell and then have the macro continue.
I was thinking about a list, for selection, but the Existing spreadsheet has many columns that user needs to look through to find the correct row.

Thank You in advance.

Ron
 
Use Application.InputBox - this can return the range selected by the user.
There is also an InputBox function (no application prefix) that returns a string.

Check out VBA help (InputBox) for the details.
--
Jim Cone
Portland, Oregon USA



"Ron Berns" <[email protected]>
wrote in message
I am learning to do Macros in Excel and I am unable to figure this problem out.
I am using Excel 2003.

I have two spreadsheets in the same workbook.
One is named Working the other is Existing.
I would like to create a macro that allows the user to
copy a row from the Existing sheet to the Working sheet.
I don't have a problem copying information from one sheet to another.
The problem I have is allowing the user to look through the information
in the Existing sheet, select a cell and then have the macro continue.
I was thinking about a list, for selection, but the Existing spreadsheet
has many columns that user needs to look through to find the correct row.
Thank You in advance.
Ron
 
Another way to do it is to tell them that you're going to copy the row with the
activecell to the other sheet.

Ask if they want to continue with the current selection at the beginning of your
code.
 
Back
Top