I have the follwoing function which loops through 3 datagrids on my page and should disable all other edit buttons when one edit button is clicked.

VB Code:
  1. Protected Sub DisableEdit()
  2.         Dim c As Control
  3.         Dim content As ContentPlaceHolder
  4.         content = Page.Master.FindControl("contentplaceholder1")
  5.  
  6.         Dim grid As GridView
  7.         Dim frow As GridViewRow
  8.  
  9.         For Each c In content.Controls
  10.             If c.GetType() Is GetType(GridView) Then
  11.                 grid = CType(c, GridView)
  12.                 For Each frow In grid.Rows
  13.                     If (frow.RowType = DataControlRowType.DataRow) Then
  14.                         If Not frow.RowState = DataControlRowState.Edit Then
  15.                             Dim btnEdit As LinkButton = frow.Cells(8).Controls(0)
  16.                             btnEdit.Enabled = False
  17.                         End If
  18.                     End If
  19.                 Next
  20.             End If
  21.         Next
  22.  
  23.     End Sub

I call this on the RowEditing of each gridview, unfortunately RowEditing Occurs when a row's Edit button is clicked, but before the GridView control enters edit mode. Which means it turns them all to false but re-binds the gridview that called the fucntion, which in turn renders all fo the controls visible.

Does anyone know of a workaround for this, or the correct event to use that will fire after the control enters edit mode