I have a radgrid I am creating dynmically including an editcolumn but when I click on the edit Column button I get the following error?
"An error has occurred because a control with id 'dgCompGrid$ctl00$ctl04$EditButton' could not be located or a different control is assigned to the same ID after postback. If the ID is not assigned, explicitly set the ID property of controls that raise postback events to avoid this error."
I have changed the grids viewstate = True but still get the same error?
If I comment out the buttontype were the column shows EDIT instead of an image button it have no problems?
I use the Needdatasource to call a sub that loads the data.
Thanks in Advance.
"An error has occurred because a control with id 'dgCompGrid$ctl00$ctl04$EditButton' could not be located or a different control is assigned to the same ID after postback. If the ID is not assigned, explicitly set the ID property of controls that raise postback events to avoid this error."
I have changed the grids viewstate = True but still get the same error?
With dgCompGrid
.Columns.Clear()
.DataSource = Nothing
.EnableViewState = True
.DataSource = ippService.Select(ID)
End With
Dim oEditColumn As New GridEditCommandColumn
With oEditColumn
.ButtonType = GridButtonColumnType.ImageButton
.UniqueName = "EditColumn"
.CancelImageUrl = "~/Images/small/x_out.gif"
.EditImageUrl = "~/Images/small/pencil.gif"
.UpdateImageUrl = "~/Images/small/save_blue.gif"
.ItemStyle.Wrap = False
End With
dgCompGrid.MasterTableView.Columns.Add(oEditColumn)
If I comment out the buttontype were the column shows EDIT instead of an image button it have no problems?
I use the Needdatasource to call a sub that loads the data.
Thanks in Advance.