473,396 Members | 2,011 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,396 software developers and data experts.

DataGrid: How to expand columnwidth to fit column contents

Hi

Is there a way to program a DataGrid control to
automatically adjust its columnwidth so it fits the
contents of the columns.

I am searching for a automated way to do the thing you do
when you manually doubleclick on the columnheader.

Yours truly

Jakob Persson
Nov 13 '05 #1
1 3126
On Wed, 16 Jul 2003 01:57:25 -0700, "Jakob Persson" <ja**********@yahoo.dk>
wrote:
Hi

Is there a way to program a DataGrid control to
automatically adjust its columnwidth so it fits the
contents of the columns.

I am searching for a automated way to do the thing you do
when you manually doubleclick on the columnheader.


http://www.syncfusion.com/FAQ/WinFor...c44c.asp#q877q

/steveA
my email Fg**********@vqk.pbz is encrypted with ROT13 (www.rot13.org)
Nov 13 '05 #2

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

Similar topics

11
by: Junkguy | last post by:
I need some help programmatically causing a row in a DataGrid to "flush" its contents to its bound data (in Visual Studio 6 using Windows Forms with C#). My issue is I want to send an update to...
0
by: Hannes | last post by:
Hello! When doubleclicking on the columnseparator of a datagrid the columnwidth ist set to the optimal size for the instantaneous content. Is there a possibility to activate this function...
1
by: BC | last post by:
Hi, Been searching the newgroups but haven't found an answer. I'm used to binding disconnected ADO recordsets to Datagrid controls and tweaking the Datagrid to suit my needs (columnheader,...
0
by: Tim_k | last post by:
Does anyone have an example of how to export a datagrid to an Excel pivot table? The code below exports the grid contents to Excel using the Response object. I'd like to expand it to show the...
1
by: Willem | last post by:
Hi, I'm using a datagrid on a webform with 4 visible and 1 invisible columns. When clicking a button I want to make the invisible column visible. I use the code DataGrid1.Columns(4).Visible =...
4
by: Paul Ilacqua | last post by:
I'm filling the datagrid with no problem but I do not see a columnwidth property anywhere. How do you set the columnwidth property of the datagrid columns in code or manually? Thank you. Paul
4
by: max | last post by:
I am not being a smartass and would honestly like an explanation, if you could take the time. What's wrong with: DataGrid.Column(0).Width = 30? or DataGrid.Column(2).Width = DataGrid.Width -...
1
by: Price Brattin | last post by:
How do I set the column width in a datagrid when the datasource is a dataview? I want to use a dataview so data changes, inserts, and deletes are disabled. I can set the column width when I use...
4
by: cooltech77 | last post by:
Hi, I am trying to build the following functionality in the datagrid. I have a lot of columns in the datagrid which are being populated from the database and the user needs to scroll...
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
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
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
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
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
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,...

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.