AZGroups.com

Bringing together Arizona Technology Users And Enhancing the Careers of Developers
Welcome to AZGroups.com Sign in | Join | Help
in Search

Problem with retrieving gridview cell values

Last post 04-11-2008, 2:52 AM by Priya. 0 replies.
Sort Posts: Previous Next
  •  04-11-2008, 2:52 AM 932

    Problem with retrieving gridview cell values

    Hi

    I just want to retrieve the cell value from the gridview using the following code,but it returns nothing

    Protected Sub GridView1_RowCommand(ByVal sender As Object, ByVal e As System.Web.UI.WebControls.GridViewCommandEventArgs) Handles GridView1.RowCommand

    Sub GridView1_RowCommand(ByVal sender As Object, ByVal e As System.Web.UI.WebControls.GridViewCommandEventArgs) Handles GridView1.RowCommand

    If e.CommandName = "Select" Then

    Dim idx As Integer = Convert.ToInt32(e.CommandArgument)

    Dim row As GridViewRow = GridView1.Rows(idx)

    LblDisplay.Text = "Customer Id: " & row.Cells(1).Text.ToString

    LblDisplay.Text = "Customer Id: " & row.Cells(1).Text.ToString

    LblDisplay.Text = "Customer Id: " & row.Cells(1).Text.ToString

    Dim row As GridViewRow = GridView1.Rows(idx)

    LblDisplay.Text = "Customer Id: " & row.Cells(1).Text.ToString

    LblDisplay.Text = "Customer Id: " & row.Cells(1).Text.ToString

    LblDisplay.Text = "Customer Id: " & row.Cells(1).Text.ToString

    Dim row As GridViewRow = GridView1.Rows(idx)

    LblDisplay.Text = "Customer Id: " & row.Cells(1).Text.ToString

    LblDisplay.Text = "Customer Id: " & row.Cells(1).Text.ToString

    LblDisplay.Text = "Customer Id: " & row.Cells(1).Text.ToString

    Dim idx As Integer = Convert.ToInt32(e.CommandArgument)

    Dim row As GridViewRow = GridView1.Rows(idx)

    LblDisplay.Text = "Customer Id: " & row.Cells(1).Text.ToString

    LblDisplay.Text = "Customer Id: " & row.Cells(1).Text.ToString

    LblDisplay.Text = "Customer Id: " & row.Cells(1).Text.ToString

    Dim row As GridViewRow = GridView1.Rows(idx)

    LblDisplay.Text = "Customer Id: " & row.Cells(1).Text.ToString

    "Customer Id: " & row.Cells(1).Text.ToString

    End If

    End Sub

    End Sub

    End Sub

    End If

    End Sub

    End Sub

     Can anyone help me to find out whats wrong with my code?

    Regards,

    Priya

    Filed under:
  • View as RSS news feed in XML
    Powered by Community Server, by Telligent Systems