Windows.Forms.DataGrid :- How to return the coloum width at runtime??

P

philip.mckee

Hi all
I am looking to return the width of a given column in a
Windows.Forms.DataGrid at runtime. This would seem to be a much needed
straight forward property request, but I can't find a simple way of
getting it. I believe the DataGridColumnStyle class should be able to
return this width, but how do you get the DataGridColumnStyle instance
for a given column? I am sure that there is a collection somewhere but
cant find.

My datagrid is constructed from a DataSet, and formatted with the
property select 'Auto Format' in the properties panel in Visual
Studio. Though this seams to simply set datagrid properties directly to
make it pretty, and not create a collection of DataGridColumnStyle or
table styles.
Thanks..
 

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