I am using GridDataBoundGrid to display data and I need hide some columns to user. But when I print this datagrid, all hidden columns are lost.
I would like to print all columns in the grid whether It is hidden or not.
Please let to me know how to print all columns if have some column are hidden.
ADAdministrator Syncfusion Team June 15, 2005 04:13 AM
If you hide the columns by setting their widths=0, then you can handle the grid.Model.QueryColWidth event and conditionally set the width to show them if you are printing. Here is a sample.
HDHoang DinhJune 15, 2005 09:33 PM
Thank for your help. And now, I can print all colums in the datagrid. But I see another issue.
The screen flash some colums when I show the datagrid.
this.dataGrid.DataSource = dt;
Result: The Col0, Col1 and Col2 in the grid is flashed.
Please help me to resolve this issue so the user doesn''t see this flashing.
ADAdministrator Syncfusion Team June 16, 2005 02:47 AM
Call this.dataGrid.BeginUpdate() before you set the datasource, and call this.dataGrid.EndUpdate after you set the ColWidths followed by this.dataGrid.Refresh().