How can I spare bandwidth while using the site?
Static Events (Guidance)
Hello Guest
  
  • Login
• Register…
• Start blog
  • Who, Where, When
• What can I do?
• What to Read?
  • Polls
• Avatars
• Interests
  • Cities and Countries
• Random blog
• Users search
  • Search
• Games
• Tests
• QAIX
  • Сообщества
• Talxy Chat
• Horoscope
• Online
 
Зарегистрируйся!

QAIX > .Net Development > Static Events (Guidance) 7 September 2006 16:49:48

  Recent blog posts: 
  They have birthday today: 
  Forums:   
  Discuss: 
  Recent forum topics: 
  Recent forum comments:
  Moderators:

Static Events (Guidance)

Robert Rolls 7 September 2006 16:49:48
 I've got a control on a Master Page that has declared a static event.
Certain pages within the site (approx 20 out 400+) need to hook up to the
event. What I'm not to sure about is how developers should code the event
handler. When the event fires within the handler developers will need to
'augment' a collection that's been calculated.



Now this collection could be passed within the event args of the event;
however if 5 pages are running concurrently only one of the pages is
interested in the event (a consequence of something they did on the page) so
I'd need to pass other data into the event that would allow the coder to see
if the event is theirs rather than another page running currently.



To help clarify: a Grid renders one of the cells is a link which causes a
click event hander to fire, within this event a navigation to another page
occurs -> when the navigation is about to happen the static event will fire.
So the other data that I could pass is where the developer was navigating
too - they can test that the target navigation is what they started and
update the collection accordingly.



Another way I could write the handler - don't pass any parameters, but
within the handler access the collection for the current navigation (the
target, I have this available globally) extract the collection for the
navigation (this is stored internally within session state) - so I could
update without concern. What I see wrong with this is the user could be
running two concurrent sessions.



All-in-all I see I need some code within the handler to determine if this
event is a result of the page or another page - what I don't quiet
understand is what's the best way to achieve this.



Rob.






===================­================
This list is hosted by DevelopMentor http://www.develop.­com

View archives and manage your subscription(s) at http://discuss.deve­lop.com

Add comment
Chris Anderson 7 September 2006 16:49:48 permanent link ]
 FWIW..this:
data into the event that would allow the coder to see if the > event is theirs rather than another page running currently.

Makes me wonder why you have this:
I've got a control on a Master Page that has declared a static event.

Why not declare it as an instance event?
-----Original Message-----> From: Discussion of building .NET applications targeted for > the Web [mailto:D­OTNET-WEB@DISCUSS.DEVELOP.COM] On Behalf Of > Robert Rolls> Sent: 07 September 2006 12:01> To: DOTNET-WEB@DISCUSS.­DEVELOP.COM> Subject: [DOTNET-WEB] Static Events (Guidance)>
I've got a control on a Master Page that has declared a static event.> Certain pages within the site (approx 20 out 400+) need to > hook up to the event. What I'm not to sure about is how > developers should code the event handler. When the event > fires within the handler developers will need to 'augment' a > collection that's been calculated.>
Now this collection could be passed within the event args of > the event; however if 5 pages are running concurrently only > one of the pages is interested in the event (a consequence of > something they did on the page) so I'd need to pass other > data into the event that would allow the coder to see if the > event is theirs rather than another page running currently.>
To help clarify: a Grid renders one of the cells is a link > which causes a click event hander to fire, within this event > a navigation to another page occurs -> when the navigation is > about to happen the static event will fire.> So the other data that I could pass is where the developer > was navigating too - they can test that the target navigation > is what they started and update the collection accordingly.>
Another way I could write the handler - don't pass any > parameters, but within the handler access the collection for > the current navigation (the target, I have this available > globally) extract the collection for the navigation (this is > stored internally within session state) - so I could update > without concern. What I see wrong with this is the user could > be running two concurrent sessions.>
All-in-all I see I need some code within the handler to > determine if this event is a result of the page or another > page - what I don't quiet understand is what's the best way > to achieve this.>
Rob.>
===================­================> This list is hosted by DevelopMentor(r) http://www.develop.­com>
View archives and manage your subscription(s) at > http://discuss.deve­lop.com>

===================­================
This list is hosted by DevelopMentor http://www.develop.­com

View archives and manage your subscription(s) at http://discuss.deve­lop.com

Add comment
 

Add new comment

As:
Login:  Password:  
 
 
  
 
Пожалуйста, относитесь к собеседникам уважительно, не используйте нецензурные слова, не злоупотребляйте заглавными буквами, не публикуйте рекламу и объявления о купле/продаже, а также материалы нарушающие сетевой этикет или УК РФ.


QAIX > .Net Development > Static Events (Guidance) 7 September 2006 16:49:48

see also:
Re: how to get found on the net
Re: How do I create a web page that…
Difference between Include and DWT
пройди тесты:
Do you know women?
see also:
ie7pro 0.9.14
Lians not Available!!!

  Copyright © 2001—2008 QAIX
Idea: Miсhael Monashev
Помощь и задать вопросы можно в сообществе support.qaix.com.
Сообщения об ошибках оставляем в сообществе bugs.qaix.com.
Предложения и комментарии пишем в сообществе suggest.qaix.com.
Информация для родителей.
Write us at:
If you would like to report an abuse of our service, such as a spam message, please .