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

2 async postbacks and EndRequestHandler

$
0
0

crazy problem here. i have a webforms page with two different calls to a web service. here's what's happening:

- AutoCompleteExtender on a textbox calls a service;

- in the Page_Load event (code behind) i'm assigning the contextKey of a SlideShowExtender (i tried a few things but this was by far the simplest and works). the SlideShowExtender calls a service and gets the right images, based on the contextKey (based on the selection in the textbox's AutoCompleteExtender.

- using

 var prm = Sys.WebForms.PageRequestManager.getInstance();

i check the slideshow's img's src attribute in the EndRequestHandler. if src is "", i hide the entire slideshow, otherwise, show it (using jquery and ele.css("","").

---

while i was working on this i added a couple of alert()s in the EndRequestHandler to check values. the img (asp:Image) was found (finally), the src was checked, the css was adjusted, all was fine and working.

then, after commenting out the alerts, the EndRequestHandler no longer worked. the extenders work, service calls are still working, but there is (apparently) no check of the image's src attribute and no more tweaking of the page. again, all i did was comment-out the alerts and now it seems the EndRequestHandler is no longer being hit.

(Note: when the alerts were there, they would pop up twice for every call. i assume once for the AutoCompleteExtender and once for the SlideShowExtender. the alerts made sense, told me exactly what i needed to know. then nothing.)

anyone run into this?


Viewing all articles
Browse latest Browse all 5678

Trending Articles



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