Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 162
Default How to disable column autosizing in Excel 2007

In Excel 2007, if you enter a number that is too big too fit in a cell,
it will automatically adjust the column width to allow the number to
fit.

I don't want that.

Anyone know how to disable it manually or via VBA?


Thanks,

Nick Hebb

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 74
Default How to disable column autosizing in Excel 2007

Nick,

I don't know how to stop this happening. However you could just set the
column widths using code and then I don't think they will change (sorry
if i'm wrong). However all number values will show as ##### if the
width is too small.

Sub changecolumnwidths()
ActiveSheet.Range("a1:g20").Select
Selection.ColumnWidth = 5
End Sub

  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 162
Default How to disable column autosizing in Excel 2007

Thanks keri. In this case the ##### display is inconsequential. I need
fixed column widths for another purpose.

- Nick

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Disable column only sorting in Excel JimG Setting up and Configuration of Excel 5 May 25th 13 05:49 AM
How do I disable the automatic virus scan when loading Excel 2007 hgreeb Setting up and Configuration of Excel 1 May 10th 09 12:50 PM
Excel 2007: How do I disable the 'Do you wish to save changes to...' when I close an un changed file? anctech Excel Discussion (Misc queries) 4 June 15th 07 10:42 AM
Autosizing labels in Excel 97 Striker475 New Users to Excel 5 November 11th 05 12:02 AM
Autosizing labels Excel 97 Striker475 Excel Discussion (Misc queries) 2 November 10th 05 02:50 AM


All times are GMT +1. The time now is 01:06 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"