+ Reply to Thread
Results 1 to 5 of 5

Using current.region less 1 column

  1. #1
    Valued Forum Contributor
    Join Date
    04-11-2006
    MS-Off Ver
    2007
    Posts
    438

    Using current.region less 1 column

    How can I use this code but tell it to select all but the right-most column?

    Why?

    I have this piece of code...

    Please Login or Register  to view this content.

    which puts the results in L2.

    The code below must come after the code above. So If I leave it as is, the code below then selects column L as part of the print area, which I don't want.


    Please Login or Register  to view this content.

    Thanks much
    Last edited by duugg; 03-31-2009 at 04:54 PM.

  2. #2
    Forum Contributor VBA Noob's Avatar
    Join Date
    04-25-2006
    Location
    London, England
    MS-Off Ver
    xl03 & xl 07(Jan 09)
    Posts
    11,988

    Re: Using current.region less 1 column

    If you leave Col L blank and place the result in say M2 then you wouldn't have a problem e.g Outside the currentregion

    Or you could try something like

    Please Login or Register  to view this content.
    VBA Noob
    Last edited by VBA Noob; 03-30-2009 at 04:17 PM.
    _________________________________________


    Credo Elvem ipsum etian vivere
    _________________________________________
    A message for cross posters

    Please remember to wrap code.

    Forum Rules

    Please add to your signature if you found this link helpful. Excel links !!!

  3. #3
    Forum Moderator - RIP Richard Buttrey's Avatar
    Join Date
    01-14-2008
    Location
    Stockton Heath, Cheshire, UK
    MS-Off Ver
    Office 365, Excel for Windows 2010 & Excel for Mac
    Posts
    29,464

    Re: Using current.region less 1 column

    Hi,

    Have you tried the .Resize instruction?

    Untested but something like:

    Please Login or Register  to view this content.
    HTH
    Richard Buttrey

    RIP - d. 06/10/2022

    If any of the responses have helped then please consider rating them by clicking the small star icon below the post.

  4. #4
    Valued Forum Contributor
    Join Date
    04-11-2006
    MS-Off Ver
    2007
    Posts
    438

    Re: Using current.region less 1 column

    I'll try these as soon as possible. Thanks

  5. #5
    Valued Forum Contributor
    Join Date
    04-11-2006
    MS-Off Ver
    2007
    Posts
    438

    Re: Using current.region less 1 column

    Thanks guys. Noob, I hadn't even thought of using M2 instead of L2. Great idea.

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

Tags for this Thread

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