This is a migrated thread and some comments may be shown as answers.

Need server-based confirm function

1 Answer 41 Views
Input
This is a migrated thread and some comments may be shown as answers.
Rich
Top achievements
Rank 1
Rich asked on 26 Sep 2010, 08:21 AM
I have a need for a server control that will perform a JS-type confirm or prompt  function and then perform a postback with the selected value from the user.

Note that this is not a client confirmation prior to running a server function, rather it is client confirmation after server procesing has already been started.

Here is the scenario:  the user submits a web page and the server logic works on it.  During processing the logic detects a condition that requires user feedback, so a control is necessary that will pop up a JS confirm/prompt and then postback the answer so that processing can continue. 

Will any of your controls do that?  If not, do you have any documentation or samples on how I could build my own control?

1 Answer, 1 is accepted

Sort by
0
Marin
Telerik team
answered on 29 Sep 2010, 12:03 PM
Hi Richard,

In ASP.NET the page's life cycle cannot be interrupted for calling a client script function and after that resuming the life cycle execution. It will be good if you can switch to a different approach. One possible option is to register a client script containing all the logic for determining whether to show client confirmation and after postback process the user's input on the server. Or you can show the confirmation on the next page load after the first postback to the server (which determines weather to show the confirmation), and then process the user input on the second postback.
  
Regards,
Marin
the Telerik team
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
Tags
Input
Asked by
Rich
Top achievements
Rank 1
Answers by
Marin
Telerik team
Share this question
or