Home > Net >  Just use DevExpress controls group, ASPxGridview operation data, the new problems and consult
Just use DevExpress controls group, ASPxGridview operation data, the new problems and consult

Time:10-19

Use the code at run time binding data source, the code is as follows:
Protected void Page_Load (object sender, EventArgs e)
{
if (! IsPostBack)
{
BindData ();
}
}

Private void BindData ()
{
The DataSet dsSQXK=SpecialtyBiz. SQXK. GetSQXK ();
View state [" SQXK "]=dsSQXK. Tables (" SQXK ");
GvSQXK. The DataSource=dsSQXK. Tables (" SQXK "),
GvSQXK. KeyFieldName="SQXKID";
GvSQXK. DataBind ();
}
Updated list in the table, have more than one field is the Combobox type, initialize the column cell is realized by using the following methods:
Protected void gvSQXK_CellEditorInitialize (object sender, ASPxGridViewEditorEventArgs e)
{
If (e.c. with our fabrication: olumn. FieldName=="XWLB")//degree category
{
If (e.K eyValue=https://bbs.csdn.net/topics/=DBNull. Value | | e.K eyValue==null) return;
ASPxComboBox CBB=e.E ditor as ASPxComboBox;
Function. The BindData. BindXWLBcbb (CBB);
}
}
Update the table of contents when all normal

The question now is:
The question now is:
The question now is:
New line, Combobox is not initialized, please how to solve,

CodePudding user response:

When you are in the new in reconstructing a datatable table binding the GV, the columns except COB assignment all empty,

CodePudding user response:

I have also been recently use DEV you must can't figure out I can offer you part of the code,

CodePudding user response:

Look on the website to see the demo with their own controls where the poor didn't write
DEV at the front desk operation as far as possible, avoid the background logic

CodePudding user response:

refer to the second floor yzf86211861 response:
I have also been recently use DEV you must can't figure out I can offer you part of the code,
thank you very much, please send me an example of a relevant in ASPxGridView use Combobox to me, especially when there is a new part of the initialization function, thank you

CodePudding user response:

((GridViewDataComboBoxColumn) gridDetail. Columns [" Accessories_type "]). PropertiesComboBox. The DataSource="AA"; GridDetail. DataBind ();
Will be ok
  • Related