A
AlecL
I have a dtagrid with two TemplateColumns one contains a textbox and
the other a imagebutton. To capture the value in the textbox when the
imagebutton is clicked I am using the itemcommand event of the
datagrid which is defined as :
<aspataGrid ID="dgproducts1" runat="server"
AutoGenerateColumns="false" Width="504px" OnItemCommand="GetRowInfo">
I have put an event handler in the page_load as:
AddHandler dgproducts1.ItemCommand, AddressOf GetRowInfo
but when the button is clicked it does not perform what is in
GetRowInfo sub whichis:
Protected Sub GetRowInfo(ByVal source As Object, ByVal e As
DataGridCommandEventArgs)
Dim prodkey As String = e.Item.Cells(3).Text
Dim prodQty As Integer = e.Item.Cells(2).Text
If e.CommandName = "btnBuyOnline" Then
Response.Redirect("store_shoppingcart.aspx?pkey=" &
prodkey & prodQty)
End If
End Sub
Please help!!!!
the other a imagebutton. To capture the value in the textbox when the
imagebutton is clicked I am using the itemcommand event of the
datagrid which is defined as :
<aspataGrid ID="dgproducts1" runat="server"
AutoGenerateColumns="false" Width="504px" OnItemCommand="GetRowInfo">
I have put an event handler in the page_load as:
AddHandler dgproducts1.ItemCommand, AddressOf GetRowInfo
but when the button is clicked it does not perform what is in
GetRowInfo sub whichis:
Protected Sub GetRowInfo(ByVal source As Object, ByVal e As
DataGridCommandEventArgs)
Dim prodkey As String = e.Item.Cells(3).Text
Dim prodQty As Integer = e.Item.Cells(2).Text
If e.CommandName = "btnBuyOnline" Then
Response.Redirect("store_shoppingcart.aspx?pkey=" &
prodkey & prodQty)
End If
End Sub
Please help!!!!