Not solved, datagrid rowheight.

  • Thread starter Thread starter Tracey
  • Start date Start date
T

Tracey

Thank you guys.
But what I meant is to automatically adjust the height of
rows in datagrid regardless of font.

For instance, the datasource of datagrid is attached to
several datagrid rows. One row holds text of 10
characters, and the text in another row is 320
characters, some other rows hold maybe 500 characters.
That is the length of text in each grid are different.

Suppose the width of datagrid column is fixed, no
expanding is allowed. How can I adjust the rowheight of
datagrid ?
 
You need to define the tablestyle

Dim dgts As New DataGridTableStyle

dgts.PreferredRowHeight = 200

DataGrid1.TableStyles.Add(dgts)
 
Thanks, but this is not the best solution. For there are
many datarows having small number of characters like 10.
If I define the tablestyle.prefereedrowheight to be 200,
the grid will look kind of empty.
 
Hello,

Ok OK, 200 is a bit over the top but thats just an example. I dont think you
can set individual rows.
 

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

Similar Threads


Back
Top