How to expand column if data in cell exceed?

C

chandan

Hi All,
I am writing in Excell using Excel Introp(COM Dll).I had try to find
expand function.But did not get there. Is there any programatic way to
expand the column while I writing in the excel when data in cell
exceed the widht of the cell.
I am using C# and VS2008 web application.

Thanks,
Chandan kumar
 
L

Leon

Microsoft.Office.Interop.Excel.WorksheetClass sheet =
new Microsoft.Office.Interop.Excel.WorksheetClass();

sheet.Columns.AutoFit();
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top