ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Worksheet Functions (https://www.excelbanter.com/excel-worksheet-functions/)
-   -   fixing column width (https://www.excelbanter.com/excel-worksheet-functions/99239-fixing-column-width.html)

John P

fixing column width
 
We create on a regular basis from Excel space delimited files for import to
other programs that require the width of the columns to be fixed. Problem
has come up that depending on which computer we are looking at the same file
a column width may be the required 4 characters wide but on the next
computer it show as 3.87 characters wide. How do we get the column width to
stay fixed at 4 no matter what computer is viewing the file? If it was only
one column this would be easy but we are talking about many columns that all
are okay on one computer but not on the other computer.



scoobz

fixing column width
 

One workaround would be to create the following macro and save it in
your workbook:

Sub auto_open()
'
Sheets("Sheet1").Select
Cells.Select
Selection.ColumnWidth = 4
Range("A1").Select
'
End Sub


--
scoobz
------------------------------------------------------------------------
scoobz's Profile: http://www.excelforum.com/member.php...o&userid=12170
View this thread: http://www.excelforum.com/showthread...hreadid=561339



All times are GMT +1. The time now is 04:42 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com