J
jinhy82
Hello! I am using DataGrid to display details from Ms Access. Fe
features such as Edit, Update and Delete are added, but they did no
function. Can anyone help me? Thank you very much!!!
For the update function, am I suppose to write the commane : UPDAT
<tablename> SET = "..."?
As I am using the "EditCommandColumn", so when I press the "Edit" link
everyfield will changed to textbox form, may I know what is that nam
for the textbox?
Here is the sub functions source code:
Sub DataGrid_Edit(ByVal obj As Object, ByVal e A
DataGridCommandEventArgs)
Dim DBACmd As New OleDbDataAdapter(SQLCmd, DBConn)
DataGrid.EditItemIndex = e.Item.ItemIndex
Response.Write(DataGrid.EditItemIndex.ToString)
DataGrid.DataBind()
End Sub
Sub DataGrid_Update(ByVal obj As Object, ByVal e A
DataGridCommandEventArgs)
DataGrid.EditItemIndex = -1
DataGrid.DataBind()
'BindGrid()
End Sub
Sub DataGrid_Cancel(ByVal obj As Object, ByVal e A
DataGridCommandEventArgs)
DataGrid.EditItemIndex = -1
DataGrid.DataBind()
'BindGrid()
End Su
features such as Edit, Update and Delete are added, but they did no
function. Can anyone help me? Thank you very much!!!
For the update function, am I suppose to write the commane : UPDAT
<tablename> SET = "..."?
As I am using the "EditCommandColumn", so when I press the "Edit" link
everyfield will changed to textbox form, may I know what is that nam
for the textbox?
Here is the sub functions source code:
Sub DataGrid_Edit(ByVal obj As Object, ByVal e A
DataGridCommandEventArgs)
Dim DBACmd As New OleDbDataAdapter(SQLCmd, DBConn)
DataGrid.EditItemIndex = e.Item.ItemIndex
Response.Write(DataGrid.EditItemIndex.ToString)
DataGrid.DataBind()
End Sub
Sub DataGrid_Update(ByVal obj As Object, ByVal e A
DataGridCommandEventArgs)
DataGrid.EditItemIndex = -1
DataGrid.DataBind()
'BindGrid()
End Sub
Sub DataGrid_Cancel(ByVal obj As Object, ByVal e A
DataGridCommandEventArgs)
DataGrid.EditItemIndex = -1
DataGrid.DataBind()
'BindGrid()
End Su