473,408 Members | 1,908 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,408 software developers and data experts.

How to change the width of an Excel Column using C#

Hello there,

i have a windows application thats automates some data from SQL Server
and exports them to Excel. I am using Windows 2000 and Excel XP. I have the
following problem :

i am trying to modify the Columns Width but it is not working.....

Have any ideas?
Giorgos....


Nov 15 '05 #1
1 18640
You should just be able to pass a type double to your
rangeobject.ColumnWidth like: It works for us.
_Range.ColumnWidth = _ColumnWidth

"Giorgos Zagouras" <gz****@cti.gr> wrote in message
news:%2****************@TK2MSFTNGP12.phx.gbl...
Hello there,

i have a windows application thats automates some data from SQL Server
and exports them to Excel. I am using Windows 2000 and Excel XP. I have the following problem :

i am trying to modify the Columns Width but it is not working.....

Have any ideas?
Giorgos....

Nov 15 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

11
by: SarahMarsden | last post by:
I'm new to Dreamweaver (using MX 2004). I have a 2 row 3 column table. I have set each column to 200 pixels. The second row I have merged into one cell. When I enter text (or anything else) into...
5
by: Johnny Meredith | last post by:
I have seven huge fixed width text file that I need to import to Access. They contain headers, subtotals, etc. that are not needed. There is also some corrupt data that we know about and can...
3
by: A Clark | last post by:
I have a subform that displays a datasheet. There are a couple of different queries that can be displayed in the datasheet. The queries are available in a combo box on the main form. The problem...
2
by: Arnie | last post by:
I have searched this NG for datasheet column width posts and have read many of them. None of them seem to address what I would like to do. I'm beginning to think what I want can't be done. Here...
0
by: Sarah | last post by:
hi.. how can i adjust the width of a column using c# in excel 2000? im not sure where to look on the net for info on this sort of stuff....please help!
1
by: Jim Heavey | last post by:
I am creating an excel file and a I am wanting to set a column with to something, say 9.20. When I run the Macro recorder, I get code which looks like the following: Columns("C:C").Select...
3
by: rn5a | last post by:
How do I change the BorderColor of the rows under the 2nd column in a DetailsView? I could change the BorderColor of the 1st column using the FieldHeaderStyle-BorderColor property but using...
2
by: sumithar | last post by:
I am trying to create a spreadsheet from mysql data. I have the requisite headers in place for content type and all that. All I am doing is executing the SQL query and displaying the data...
3
by: Csaba Gabor | last post by:
I have a table with 3 rows, and two pieces of data to display in each row. However, the first element of the last two rows and the 2nd element of the 1st row are very short. This would seem to...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.