+ Reply to Thread
Results 1 to 3 of 3

Syntax To Add A Variable to a Range

  1. #1
    Forum Contributor
    Join Date
    10-29-2019
    Location
    London, England
    MS-Off Ver
    2013
    Posts
    156

    Syntax To Add A Variable to a Range

    Hi, im trying to add a variable to a range, something like this Set myRange = Range("A70:lRow"), but cant figure out the syntax.

    Thanks.

    Please Login or Register  to view this content.

  2. #2
    Forum Expert Pepe Le Mokko's Avatar
    Join Date
    05-14-2009
    Location
    Belgium
    MS-Off Ver
    O365 v 2402
    Posts
    13,448

    Re: Syntax To Add A Variable to a Range

    In the future please post in the correct forum (VBA in this case). I will move it there

  3. #3
    Forum Guru
    Join Date
    03-02-2006
    Location
    Los Angeles, Ca
    MS-Off Ver
    WinXP/MSO2007;Win10/MSO2016
    Posts
    12,612

    Re: Syntax To Add A Variable to a Range

    Set myRange = Range("A70:" & lRow)

    - or -
    Please Login or Register  to view this content.
    Last edited by protonLeah; 02-05-2020 at 05:41 PM.
    Ben Van Johnson

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. Cant Figure Out Syntax For Range As A Variable
    By Genus Max in forum Excel Programming / VBA / Macros
    Replies: 6
    Last Post: 01-26-2020, 10:05 AM
  2. cell range variable syntax
    By Estaban9850! in forum Excel Formulas & Functions
    Replies: 6
    Last Post: 03-28-2016, 09:44 AM
  3. [SOLVED] Syntax for Using Range with a Variable Column
    By Gard5096 in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 01-31-2013, 12:36 PM
  4. Refer to a range(row 20 : variable), syntax help
    By VBAHelpMe in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 04-16-2009, 09:01 AM
  5. Syntax for Range command with a variable
    By nebb in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 08-11-2007, 12:14 PM
  6. syntax - range name as a variable
    By Peter Morris in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 08-04-2006, 02:15 PM
  7. Syntax to Set variable range
    By Mike Fogleman in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 12-10-2005, 05:15 PM

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