+ Reply to Thread
Results 1 to 2 of 2

How to autofit a selection of columns?

  1. #1
    Forum Contributor
    Join Date
    04-11-2011
    Location
    Columbus, Ohio
    MS-Off Ver
    Excel 2007
    Posts
    325

    How to autofit a selection of columns?

    Please Login or Register  to view this content.


    I've been trying to use a function I found from ozgrid.com to get a variable column. However, I am unsure of the syntax to autofit the columns in Sub test() and also convert a .Address to whatever it is supposed to be. Can someone show me what syntax I should be using here?

    Thanks in advance.
    Last edited by 111StepsAhead; 04-09-2012 at 10:18 AM.

  2. #2
    Forum Expert
    Join Date
    09-20-2011
    Location
    England
    MS-Off Ver
    Excel 2010
    Posts
    2,278

    Lightbulb Re: How to autofit a selection of columns?

    Hello
    I'm not an expert with VBA but if you're trying to autofit all your columns containing headings on the Main sheet then something like the following code works for me.

    Please Login or Register  to view this content.
    Hope this helps.

+ 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