+ Reply to Thread
Results 1 to 5 of 5

How to Select a Whole Column Using Cells(1,1) Style?

  1. #1
    Registered User
    Join Date
    04-22-2012
    Location
    Ontario, Canada
    MS-Off Ver
    Excel 2010
    Posts
    15

    How to Select a Whole Column Using Cells(1,1) Style?

    In the macro below, how would I convert "Columns("B:B").Select" to the "Cells(1,1)" approach so that I can start using variables and delete as many columns as I want? I've tried the obvious substitutions but seem to have the syntax slightly wrong.

    Thank you.


    Please Login or Register  to view this content.

  2. #2
    Forum Expert Bob Phillips's Avatar
    Join Date
    09-03-2005
    Location
    Wessex
    MS-Off Ver
    Office 2003, 2010, 2013, 2016, 365
    Posts
    3,284

    Re: How to Select a Whole Column Using Cells(1,1) Style?

    Please Login or Register  to view this content.

  3. #3
    Forum Expert mrice's Avatar
    Join Date
    06-22-2004
    Location
    Surrey, England
    MS-Off Ver
    Excel 2013
    Posts
    4,967

    Re: How to Select a Whole Column Using Cells(1,1) Style?

    Try

    Please Login or Register  to view this content.
    or

    Please Login or Register  to view this content.
    Martin

  4. #4
    Forum Expert Paul's Avatar
    Join Date
    02-05-2007
    Location
    Wisconsin
    MS-Off Ver
    2016/365
    Posts
    6,885

    Re: How to Select a Whole Column Using Cells(1,1) Style?

    Hi Enos,

    Do you mean something like..
    Please Login or Register  to view this content.
    You could use Cells() references instead, but they work the same.

  5. #5
    Registered User
    Join Date
    04-22-2012
    Location
    Ontario, Canada
    MS-Off Ver
    Excel 2010
    Posts
    15

    Re: How to Select a Whole Column Using Cells(1,1) Style?

    Thank you, gentlemen--that solves my problem completely.

+ 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