+ Reply to Thread
Results 1 to 2 of 2

How do I pause a macro to select specific cells

  1. #1
    lee
    Guest

    How do I pause a macro to select specific cells

    I am using version Excel 2003 - I need to be able to pause a macro to allow
    me to select specific cells (which will be different each time I use the
    macro) then continue to run the rest of the macro.

  2. #2
    Dave Peterson
    Guest

    Re: How do I pause a macro to select specific cells

    You could use application.inputbox()

    As in:

    dim myRng as range

    set myrng = nothing
    on error resume next
    set myrng = application.inputbox("Select a range", type:=8)
    on error goto 0

    if myrng is nothing then
    'user hit cancel
    'what happens here
    else
    msgbox myrng.address 'do what you want
    end if

    lee wrote:
    >
    > I am using version Excel 2003 - I need to be able to pause a macro to allow
    > me to select specific cells (which will be different each time I use the
    > macro) then continue to run the rest of the macro.


    --

    Dave Peterson

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1