473,387 Members | 1,549 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,387 software developers and data experts.

Asp.NET, Ajax, Usercontrols, Event bubbling

Hello folks, I'm in trouble with an application using methodologies in
subject.

The idea is to have a single-page application. The host aspx page
coordinates all visualizations, loading and populating different
usercontrols on a status basis.

To listen for changes I'm bubbling up events from the usercontrols.
Each event raises up to the host aspx page, which decides what to do,
what to load etc.

I have to say that this works on a non-ajax environment.

My problem is that, using updatepanels, the result I get is similar to
a full-postback, everything is updated after an event, even those
updatepanels I want to keep not up-to-date.
This, I suppose, is due to the fact that, having to recreate runtime
usercontrols on page_init (otherwise events are not listened),
everything is seen as modified and posted back to client. This is what
I think but maybe I'm wrong.

I tried to do a proof-of-concept of this situation, maybe something is
missing but reproduces the problem.

I can't attach from this interface, so you can find the zip file on
following url:
http://snipurl.com/24sfn

As you can see, even being in separated updatepanels, everything is
updated on postback

Thanks in advance,
mt
Jun 27 '08 #1
1 1294
you need to understand the update panel model. with an update panel, all
data is posted back, and a complete page processing cycle is done. the
only trick, with a panel, is only the html in the panel(s) is sent back
to the client, and the panels inner html is updated.

-- bruce (sqlwork.com)

m.*********@gmail.com wrote:
Hello folks, I'm in trouble with an application using methodologies in
subject.

The idea is to have a single-page application. The host aspx page
coordinates all visualizations, loading and populating different
usercontrols on a status basis.

To listen for changes I'm bubbling up events from the usercontrols.
Each event raises up to the host aspx page, which decides what to do,
what to load etc.

I have to say that this works on a non-ajax environment.

My problem is that, using updatepanels, the result I get is similar to
a full-postback, everything is updated after an event, even those
updatepanels I want to keep not up-to-date.
This, I suppose, is due to the fact that, having to recreate runtime
usercontrols on page_init (otherwise events are not listened),
everything is seen as modified and posted back to client. This is what
I think but maybe I'm wrong.

I tried to do a proof-of-concept of this situation, maybe something is
missing but reproduces the problem.

I can't attach from this interface, so you can find the zip file on
following url:
http://snipurl.com/24sfn

As you can see, even being in separated updatepanels, everything is
updated on postback

Thanks in advance,
mt
Jun 27 '08 #2

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

Similar topics

5
by: Mark Szlazak | last post by:
Apparently there is a textarea onscroll event bubbling bug in Firefox and Mozilla: https://bugzilla.mozilla.org/show_bug.cgi?id=229089 I'm trying to check for this bug with the following...
4
by: Wee Bubba | last post by:
the following event handler checks to see if any parent control has attached to the event 'SearchItemSelect'. i use it for event bubbling whenever one of my search items has been selected and at...
7
by: Girish | last post by:
OK.. phew. Playing with data grids for the past few days has been fun and a huge learning experience.. My problem. I have a requirement to display a gird with a gird. Within the embedded grid,...
7
by: comzy | last post by:
I have created an event bubbling for my pager control which is used for implementing paging in data grid. Althoug it worked very fine in .NET 1.1 it is throwing the following error after i migrated...
17
by: dan_williams | last post by:
I have the following test web page:- <html> <head><title>Test</title> <script language="Javascript"> <!-- function fnTR() { alert("TR"); }
2
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...
3
by: JacekDr | last post by:
Hello, I've got the following problem: I want to add and remove dynamically controls to UpdatePanel. In my user control I have a button, but when I click it I get AsyncPostback and Event for...
2
by: alhalayqa | last post by:
hi, in MSIE, you can attach onclick event to both anchor and document objects. here is some code : document.onclick = function() {alert('document clicked ...'); } <a href= " " ...
6
by: =?Utf-8?B?RGFuaWVs?= | last post by:
Hi, I'm building a site with Visual Studio 2008 utilizing ajax extension. The page works fine on IE7/FireFox, but on IE6, each action on the page will cause an entire page refresh. Basically the...
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
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
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
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
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...

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.