0

I have this link button:

<asp:ButtonColumn Text="Return to Clinic" ItemStyle-CssClass="btnLinkBtn" ButtonType="LinkButton" CommandName="Return" HeaderText="Action">
      <ItemStyle HorizontalAlign="Center" Width="30px"/>
      <HeaderStyle HorizontalAlign="Center" Width="30px"/>
</asp:ButtonColumn>

The the code behind is this:

Protected Sub dgRequests_ItemCommand(source As Object, e As DataGridCommandEventArgs) Handles dgRequests.ItemCommand
    Try
        If e.CommandName = "Return" Then

            divReturnToClinicPanel.Visible = True
            divContent.Visible = False

            ' More code here

        End If
    Catch ex As Exception
        ' ... 
    Finally
        ' ... 
End Sub

The problem is that the first click doesn't fire anything, only the second one. What could be the problem?

Emi
  • 1,165
  • 4
  • 15
  • 26

0 Answers0