+ Reply to Thread
Results 1 to 3 of 3

Range Parameters as Variables

  1. #1
    Registered User
    Join Date
    06-13-2008
    Posts
    21

    Range Parameters as Variables

    Hi,

    I am using a macro to create a graph, I would like to make the two range paramaters variables and get them from the user using inputboxes.

    I know how to get the values using input boxes and assign them to variable names, but i do not know how to then make these variables the Range parameters.

    Please Login or Register  to view this content.
    "A7" and "K10" would become variables.

    what i would like is Range(var1, var2).Select

    jonnyuk3

  2. #2
    Valued Forum Contributor Richard Schollar's Avatar
    Join Date
    05-23-2006
    Location
    Hampshire UK
    MS-Off Ver
    Excel 2002
    Posts
    1,264
    Hello Jonny

    if you want the users to specify an entire range to use, you don't need two parameters - you can get away with just the one:

    Please Login or Register  to view this content.
    Richard

  3. #3
    Registered User
    Join Date
    06-13-2008
    Posts
    21
    Richard,

    Thanks for the reply.

    How do you mean
    'rngToChart then holds a range reference to the range selected by the user which you can use as you wish
    I tried to use Range(rngToSelect).Select but i get a Method 'Range' of object ' _Global' failed.

    Doesn't matter mate, i got it 'rngToSelect.Select'

    Thanks

    jonnyuk3
    Last edited by jonnyuk3; 07-31-2008 at 09:15 AM.

+ 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