Quantcast
Channel: ASP.NET AJAX + Ajax Control Toolkit (ACT)
Viewing all articles
Browse latest Browse all 5678

How to set values in side Updatepanel events and access in code

$
0
0

Im using ajax update panel to show the progress of send email in asp.net. user will submit/approve/decline a case depend on their user role. when user decline, system will asks for java script confirmation, if selected OK , the server side code will be executed. all these works fine with out using a update panel.but i cannot show email sending delay using a wait progress image.

issue is when i use update panel , i have java script code initialrequest and EndRequest events. in initial request event i check the name of button clicked using document.getelementsbyname method of document object and check for confirmation.here if user clicks "OK", i want to set a value to hidden text, hdnDeclined.value="Yes", so i will check it in cmdDeclined_click server code to executes the code. also i will use this value in "EndRequest" event to display "Case is successfully declined" if hdnDeclined.value="Yes".

i tried canceling refreshing the updatepanel using args.set_cancel(true), is initialRequest event, but when user verify details and clicks on same button or another button and even the screen is not validated the "please wait..." image appears and the screen hangs.if i dont use args.set_cancel(true) all works fine, but i cannot read the value i set for hiddenDeclined in code.

all my buttons, hidden textboxes are inside update panel.

please help.


Viewing all articles
Browse latest Browse all 5678

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>