Jump to content

Welcome to Geeks to Go - Register now for FREE

Geeks To Go is a helpful hub, where thousands of volunteer geeks quickly serve friendly answers and support. Check out the forums and get free advice from the experts. Register now to gain access to all of our features, it's FREE and only takes one minute. Once registered and logged in, you will be able to create topics, post replies to existing threads, give reputation to your fellow members, get your own private messenger, post status updates, manage your profile and so much more.

Create Account How it Works

Column widths in Excel

  • Please log in to reply




  • Member
  • PipPipPip
  • 343 posts
I am using Microsoft Excel 2007. I receive many different documents during the week with a different number of columns in each. But the one thing they have in common is that they each have A LOT of columns. With each file, I need to find out all of its column widths. I've been doing this one column at a time--right clicking on the column header, clicking on "column width," and making a note of the number listed.

But it dawned on me that it might be possible to generate some type of report or something in Excel that will display the width of all columns with data in it. Is there a way to do just that?

  • 0





  • Member
  • PipPip
  • 98 posts

the following VBA lines should get you started
you could use debug.print or msgbox to display the results

a = Columns("A:A").ColumnWidth
Debug.Print "Column A width = ", a

b = Columns("B:B").ColumnWidth
Debug.Print "Column B width = ", b

  • 0

Similar Topics

0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users

As Featured On:

Microsoft Yahoo BBC MSN PC Magazine Washington Post HP