473,490 Members | 2,472 Online
Bytes | Software Development & Data Engineering Community
Create Post

Home Posts Topics Members FAQ

ASP.NET/Ajax Question

I am running ASP.NET 2.0 with Ajax.
I am invoking an asyncronous postback by invoking a button click which
triggers the async postback. This works fine, but I need to take into
consideration the success or not of the request.
//Pseudo Code.
Jun 27 '08 #1
3 1111
Sorry - This should have been pasted

I am running ASP.NET 2.0 with Ajax.
I am invoking an asyncronous postback by invoking a button click which
triggers the async postback. This works fine, but I need to take into
consideration the success or not of the request.
//Pseudo Code.
__doPostBack( 'btnMyButton.......

alert('Thank you, your request has been completed');
OK, no what is happening of course is that the alert pops up before the
relative update panels are updated on the client.

I need to be able to

a.) Sync my 'Thank You' Message with the reuest being complete.
b.) Take into consideration that a timeout may occur.
Any constrcutive suggestions to do this would be greatly appreciated.

Thanks ....

//Pseudo Code.


Jun 27 '08 #2
On Jun 17, 7:21*am, "Microsoft Newsserver" <m...@nowhere.comwrote:
>
__doPostBack( 'btnMyButton.......

alert('Thank you, your request has been completed');

OK, no what is happening of course is that the alert pops up before the
relative update panels are updated on the client.

I need to be able to

* * a.) Sync my 'Thank You' Message with the reuest being complete.
* *b.) Take into consideration that a timeout may occur.
Why not replace your javascript alert with a Modal Popup Extender? if
the latter is in the update panel, it would be in sync with the
partial postback and you'd (probably) have enough control over it
server side to handle the timeout issue.
Jun 27 '08 #3
assuming you are using the ajax library for the postback, you use the
Sys.WebForms.PageRequestManager class to register a handler for the
endRequest Event:

Sys.WebForms.PageRequestManager.getInstance().add_ endRequest(callback);

the callback will be passed an error if there is one.

-- bruce (sqlwork.com)
"Microsoft Newsserver" wrote:
Sorry - This should have been pasted

I am running ASP.NET 2.0 with Ajax.
I am invoking an asyncronous postback by invoking a button click which
triggers the async postback. This works fine, but I need to take into
consideration the success or not of the request.
//Pseudo Code.
__doPostBack( 'btnMyButton.......

alert('Thank you, your request has been completed');
OK, no what is happening of course is that the alert pops up before the
relative update panels are updated on the client.

I need to be able to

a.) Sync my 'Thank You' Message with the reuest being complete.
b.) Take into consideration that a timeout may occur.
Any constrcutive suggestions to do this would be greatly appreciated.

Thanks ....

//Pseudo Code.


Jun 27 '08 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

10
2040
by: G Matthew J | last post by:
interesting "signal vs. noise" blog entry: http://37signals.com/svn/archives2/whats_wrong_with_ajax.php
21
6086
by: javainfo | last post by:
How can i refresh IFRAME and load data through AJAX?
9
1662
by: darrel | last post by:
Last week I asked about ASP.net 2.0 AJAX frameworks and there appears to be several to choose from. I haven't used ASP.net 2.0 yet, but from doing a bit of reading, it appears that ASP.net 2.0...
31
3070
by: Tony | last post by:
I just noticed that prototype.js is one of the files in the Ajax.NET distribution - I'm pretty concerned about this. Does anyone know if this is the same "prototype.js" that is not well-liked...
1
1832
by: codefragment | last post by:
Hi I have asked this on the official asp.net forums but no luck so thought I'd try here Assume you have a page with a filter control and a grid view and many other controls on it. When the...
8
1689
by: =?Utf-8?B?V2ViQnVpbGRlcjQ1MQ==?= | last post by:
I'm about to finally make the jump and start a new site using AJAX. THe question i have for all of you AJAX developers out there is which one? 1. The Standard AJAX frame work 2. The Tool kit....
2
2191
by: =?Utf-8?B?VG9u?= | last post by:
Hello, I want to understand teh benefits of ajax technology. Does anyone has a good website where AJAX EXTENSIONS is worked out so I really understand it. There a 2 main questions: 1) How about...
2
1583
by: Cirene | last post by:
3 quick questions... 1. Are the controls in the AJAX Futures download "beta" or the release and stable version? 2. Also, where is the best way to learn how to implement these? (Other than by...
6
1538
by: Jonathan Wood | last post by:
Greetings, I'd like to implement some AJAX features on an existing ASP.NET site. I have one example of doing this but, otherwise, don't know much about it. I have one question, though, about...
22
1664
by: sheldonlg | last post by:
I am looking for a clean solution to a problem that I solved in, what I call, a "dirty" way. Here is what I want to do. I have a dropdown list. Clicking on an item in the dropdown list invokes...
0
7112
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
6974
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
7146
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
7183
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
1
6852
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
7356
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
5448
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
3074
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
0
277
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.