New to Telerik UI for ASP.NET AJAXStart a free 30-day trial

PreRender Event

Fired when the server control is about to render to its containing Page object.

Event Parameters

  • (object) sender

    • The control that fires the event
  • (EventArgs) e

    • Does not contain arguments

Attaching the event

In the Markup

ASP.NET
<telerik:RadGrid ID="RadGrid1" runat="server" OnPreRender="RadGrid1_PreRender">
</telerik:RadGrid>

In the Code behind

C#
protected void Page_Init(object sender, EventArgs e)
{
    RadGrid1.PreRender += RadGrid1_PreRender;
}

The event handler

C#
protected void RadGrid1_PreRender(object sender, EventArgs e)
{
    //execute some logic
}

See Also