format syncfusion grid grouping control for windows application
I am using custom generic collection class to bind data with datasource of grid grouping control.
List c = new List();
now "CustomClass" have all properties..
to bind data with grid grouping control i am using syntax
this.gridGroupingControl1.DataSource = c;
This binds my grid properly....but i don't want to bind grid directly....because the grid header displays the same name as written in "CustomClass" properties....i want to give differnt header name in grid grouping control (not what i have written in "CustomClass") and for all columns i want to give different column width...and one more thing that how to make autogenerate column= false in grid grouping control
I will be really thankfull if anyone could help me in this...
List
now "CustomClass" have all properties..
to bind data with grid grouping control i am using syntax
this.gridGroupingControl1.DataSource = c;
This binds my grid properly....but i don't want to bind grid directly....because the grid header displays the same name as written in "CustomClass" properties....i want to give differnt header name in grid grouping control (not what i have written in "CustomClass") and for all columns i want to give different column width...and one more thing that how to make autogenerate column= false in grid grouping control
I will be really thankfull if anyone could help me in this...
SIGN IN To post a reply.
3 Replies
HA
haneefm
Syncfusion Team
August 24, 2007 08:14 PM UTC
Hi Prabhjeet,
Regarding the Column's HeaderText:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
You can change the header text of the column by using the GridColumnDescriptor.HeaderText property. Below is a code snippet
this.gridGroupingControl1.TableDescriptor.Columns["ColumnName"].HeaderText = "ChangeHeaderText";
GridTableDescriptor td2 = gridGroupingControl1.GetTableDescriptor("Table2");
td2.Columns["Nothing much"].HeaderText = "ChangeHeaderText";
Regarding the Column's width:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
To change the individual column width manually, you could try this code snippet:
this.gridGroupingControl1.TableDescriptor.Columns["ColumnName"].Width = 175;
//For paticular table.
this.gridGroupingControl1.GetTableDescriptor("TableName").Columns["ColumnName"].Width=50;
Here is a forum thread that discuss with simillar issue.
http://www.syncfusion.com/support/Forums/message.aspx?&MessageID=54487
Best regards,
Haneef
Regarding the Column's HeaderText:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
You can change the header text of the column by using the GridColumnDescriptor.HeaderText property. Below is a code snippet
this.gridGroupingControl1.TableDescriptor.Columns["ColumnName"].HeaderText = "ChangeHeaderText";
GridTableDescriptor td2 = gridGroupingControl1.GetTableDescriptor("Table2");
td2.Columns["Nothing much"].HeaderText = "ChangeHeaderText";
Regarding the Column's width:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
To change the individual column width manually, you could try this code snippet:
this.gridGroupingControl1.TableDescriptor.Columns["ColumnName"].Width = 175;
//For paticular table.
this.gridGroupingControl1.GetTableDescriptor("TableName").Columns["ColumnName"].Width=50;
Here is a forum thread that discuss with simillar issue.
http://www.syncfusion.com/support/Forums/message.aspx?&MessageID=54487
Best regards,
Haneef
PR
prabhjeet
August 25, 2007 02:23 PM UTC
thx a lot haneef....all ur ans were v helpfull....
i will be v thankull if u could also help me i following queries....
1) In my application i when i single click on grid grouping cell then it becomes editable but i want that instead of single click when i double click the cell should be editable..
2) by default all cells are editable in grid grouping control...i want make some cells editable and some non editable.....
3) When i bind "data time" to grid grouping control...it displays date time in editable callender......i don't want to create editable callender...just display the date time in normal cell...
4) in my application my grid gets refreshed after every one second...now when i am editing something the focus of edit cell changes and i am not able to edit my grid...i cannot stop the data reciving at my grid...so kindly help how to edit grid in above situation...
i will be v thankfull if anyone could help me in all my above queries...
>Hi Prabhjeet,
Regarding the Column's HeaderText:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
You can change the header text of the column by using the GridColumnDescriptor.HeaderText property. Below is a code snippet
this.gridGroupingControl1.TableDescriptor.Columns["ColumnName"].HeaderText = "ChangeHeaderText";
GridTableDescriptor td2 = gridGroupingControl1.GetTableDescriptor("Table2");
td2.Columns["Nothing much"].HeaderText = "ChangeHeaderText";
Regarding the Column's width:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
To change the individual column width manually, you could try this code snippet:
this.gridGroupingControl1.TableDescriptor.Columns["ColumnName"].Width = 175;
//For paticular table.
this.gridGroupingControl1.GetTableDescriptor("TableName").Columns["ColumnName"].Width=50;
Here is a forum thread that discuss with simillar issue.
http://www.syncfusion.com/support/Forums/message.aspx?&MessageID=54487
Best regards,
Haneef
i will be v thankull if u could also help me i following queries....
1) In my application i when i single click on grid grouping cell then it becomes editable but i want that instead of single click when i double click the cell should be editable..
2) by default all cells are editable in grid grouping control...i want make some cells editable and some non editable.....
3) When i bind "data time" to grid grouping control...it displays date time in editable callender......i don't want to create editable callender...just display the date time in normal cell...
4) in my application my grid gets refreshed after every one second...now when i am editing something the focus of edit cell changes and i am not able to edit my grid...i cannot stop the data reciving at my grid...so kindly help how to edit grid in above situation...
i will be v thankfull if anyone could help me in all my above queries...
>Hi Prabhjeet,
Regarding the Column's HeaderText:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
You can change the header text of the column by using the GridColumnDescriptor.HeaderText property. Below is a code snippet
this.gridGroupingControl1.TableDescriptor.Columns["ColumnName"].HeaderText = "ChangeHeaderText";
GridTableDescriptor td2 = gridGroupingControl1.GetTableDescriptor("Table2");
td2.Columns["Nothing much"].HeaderText = "ChangeHeaderText";
Regarding the Column's width:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
To change the individual column width manually, you could try this code snippet:
this.gridGroupingControl1.TableDescriptor.Columns["ColumnName"].Width = 175;
//For paticular table.
this.gridGroupingControl1.GetTableDescriptor("TableName").Columns["ColumnName"].Width=50;
Here is a forum thread that discuss with simillar issue.
http://www.syncfusion.com/support/Forums/message.aspx?&MessageID=54487
Best regards,
Haneef
HA
haneefm
Syncfusion Team
August 28, 2007 12:44 AM UTC
Hi prabhjeet,
Please refer this.
http://www.syncfusion.com/support/Forums/message.aspx?&MessageID=67634
Best regards,
Haneef
Please refer this.
http://www.syncfusion.com/support/Forums/message.aspx?&MessageID=67634
Best regards,
Haneef
SIGN IN To post a reply.
- 3 Replies
- 2 Participants
-
PR prabhjeet
- Aug 24, 2007 07:10 AM UTC
- Aug 28, 2007 12:44 AM UTC