Hi,
cant figure out where to set the new datagrid width to fit all the columns.
I define a tablestyle and count the total width of the columns
Oke this is what i do (try)
1. load the form
2. add dgStyle to datatable
(here I calculate (intdgCursWidth) the width of all colums, which I want to use for adjusting the width of the datagrid)
3. bind datatable to datagrid
But in whatever event I put this line:
The datagrid is NOT resized to the calc size (intdgCursWidth)
Cant figure this out, where do I put this line of code?
Someone? ideas? solutions?
thanks
cant figure out where to set the new datagrid width to fit all the columns.
I define a tablestyle and count the total width of the columns
Oke this is what i do (try)
1. load the form
2. add dgStyle to datatable
(here I calculate (intdgCursWidth) the width of all colums, which I want to use for adjusting the width of the datagrid)
3. bind datatable to datagrid
But in whatever event I put this line:
VB.NET:
[SIZE=2][COLOR=#0000ff]
Me[/COLOR][/SIZE][SIZE=2].dgCursisten.Width = intdgCursWidth
[/SIZE]
Cant figure this out, where do I put this line of code?
Someone? ideas? solutions?
thanks