WebButton FlyPostBack OnClicked event

9 replies. Last post: December 10, 2013 10:22 PM by Bernard Xiang
Tags :
  • (None)
  • New Discussion
  • New Question
  • New Product Feedback
roi ukashiMember

Hello, 

I'm trying to figure out how to prevent the "OnClicked" event(server side) of a WebButton

from within some inheritted base page (On_Init event) in case session has ended, and actually redirect the user into another page without allowing the event to fire.

I have tried Response.Redirect and even Page.ClientScript.RegisterClientScriptBlock prior to invoking the event, but nothing seemed to work. I believe something is interfering with FlyPostBack mechanism(?)

Help would be much appreciated!


I'm using the following control & code:

<ISWebDesktop:WebButton ID="bttn" runat="server"  Height="20px" Width="150px" 

                                            Text="Click" DisplayMode="Text" AutoPostback="true" TabIndex="108"

                                            OnClientClick="bttn_OnClientClick" OnClicked="bttn_OnClicked">

<FlyPostBackSettings PostHiddenFields="True" PostInputControls="True" />

</ISWebDesktop:WebButton>


protected void bttn_OnClicked(object sender, WebButtonClickedEventArgs e)

{

...

bttn.ClientAction.InvokeScript("JSFunc();");

}

All times are GMT -5. The time now is 9:24 AM.
Previous Next