Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming,microsoft.public.vb.ole.automation
|
|||
|
|||
Resize an Excel Column from VB
Hi,
I'm using Office XP and I'm trying to use VB (from Access) to resize a columns in Excel based on the text (size to fit). How can I do this? Thanks in advance. |
#2
Posted to microsoft.public.excel.programming,microsoft.public.vb.ole.automation
|
|||
|
|||
Resize an Excel Column from VB
Dim ws As Excel.Worksheet
Set ws = oXLApp.Worksheets("Your worksheet name") ws.Columns("A:A").EntireColumn.AutoFit This assumes that you have some reference to the application, which is oXLApp in this sample code. |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
how do i resize column letters in excel 2007 | Excel Worksheet Functions | |||
how do I resize a range of cells in a column in excel? | Excel Discussion (Misc queries) | |||
how do I resize only a part of a column in excel? | Excel Discussion (Misc queries) | |||
I could NOT resize the axis title but excel allows me to resize gr | Charts and Charting in Excel | |||
I could NOT resize the axis title but excel allows me to resize gr | Charts and Charting in Excel |