Ask a Question related to ASP.NET Building Controls, Design and Development.
-
Amar #1
Added CheckBox to a DataGrid Doesn't work with DataGrid.Enabled=False
I have created a Template Column and Added to a Datagrid, which
contains a checkBox. The column is not Binded to any column of the
Dataset, but is an extra one so i can retrieve on Save Button which
rows are selected and make the necessary work. The problem is that my
page has 3 states. The 1 one is when form is first loaded. When i
click the Save button the Page goes to state 2 and the DataGrid must
become Enabled = false, in order to ask from the user a confirmation
about the data, and finally when Save button is clicked again the
transaction must take place. At that point when i try to determine
which check boxes are selected through (which is correct):
foreach(DataGridItem mItem in CAssigned.Items){
CheckBox mBox = (CheckBox)cItem.Cells[CAssigned.GetCheckBoxColumnIndex()].Controls[0];
if (mBox.Checked){
countCheckBox ++;
}
}
all the checkboxes are unselected.
WHEN i don't make DataGrid Enabled = false and leave it always enabled
i get always the correct values at the 3rd state of my form. Maybe
something is going wrong with Enabled property of the DataGrid?
Please Help!.
Amar Guest
-
Howto bind CheckBox to the datagrid/ Then update the database field when the checkbox is clicked.
I am trying to update the database field when the checkbox is clicked. I am trying to modified the following solution but.. got stuck on the... -
CheckBox in DataGrid .
How can I judge which checkbox is checked ? for(int i=0;i<dgOrderList.Items.Count;i++) { CheckBox... -
Enabled set to false but still able to use datagrid
On my ASP.NET page (using VB.NET) when the user performs a particular action on the page I wish the datagrids to be disabled and not allow their page... -
DataGrid empty on Postback with ViewState enabled
Hi there! I'm having a problem with the datagrid control. I can't seem to get the datagrid to restore it's contents from ViewState. A... -
Datagrid Enabled = false - Not Working.
Hi All, I'm using a datagrid to display and edit pricing data. The grid uses the LinkButtons for editing deleting etc. I want to lock the...



Reply With Quote

