Click here to Skip to main content
15,893,381 members
Please Sign up or sign in to vote.
1.00/5 (1 vote)
See more:
hi friends good morning to all...

"develop a login Control which consists of User name text, Password Textbox & button (Submit).
Design must be in User Control & Coding must be in Page which u have inherited user control.
By Using Event bubbling coding..

That is my Task....here i develop a usercontrol page with requirement but iam not able to write the bussiness logic code by using the EVENT BUBBLING Mechanism pleas try to me frnds......
Posted
Comments
Ron Beyer 8-Dec-13 22:57pm    
This question does not make a lot of sense. Event bubbling is the process by which events are passed up (or down with routing). You don't code something "using event bubbling", event bubbling may be a feature of your control, but its not a method for programming it.
Sergey Alexandrovich Kryukov 8-Dec-13 23:02pm    
Not even so: event bubbling should be a technique of the UI framework. We cannot modify browsers and change the standards they are based on. If bubbling is not a feature of the framework and/or a platform, inventing controls with such feature is just useless. I hope this is what you meant... :-)
—SA
Ron Beyer 8-Dec-13 23:12pm    
I was ignoring the ASP.NET part of it and focusing on the user control part... It could be a browser based XBAP or something, but certainly doesn't fit the ASP.NET model like you said.
Sergey Alexandrovich Kryukov 8-Dec-13 23:41pm    
Exactly; please see my speculations below... :-)
—SA
Sergey Alexandrovich Kryukov 8-Dec-13 23:59pm    
Oh, it looks like we overlooked something: please see the comment and the answer by Bill...
—SA

1 solution

See [^] for a good discussion of event-bubbling and UserControl inheritance in ASP.NET. And: [^].

For "up event bubbling" in JavaScript, see: [^].

When you create an instance of a UserControl, the UserControl instance is a dynamic entity based on its code definition: it doesn't quite make sense to say that the UserControl "inherits" its code definition, just as you wouldn't say a building "inherits" its blueprints.

If you create a UserControl definition, and then create another UserControl definition that inherits from it, you might imagine this as being one set of blueprints that uses/references another set of blueprints.

I suggest you ask your instructor for clarification of what they mean by using "event bubbling" in this assignment: ask if they mean something more than just having Event Handlers defined in some containing entity that holds the log-in dialog.
 
Share this answer
 
Comments
Sergey Alexandrovich Kryukov 8-Dec-13 23:56pm    
I see. First of all, in my comment I inverted the direction of event propagation in my description of it. Secondly, I somehow wasn't aware of bubbling invocation and handling. Even though I don't do ASP.NET development, I should be more familiar with that. The MSDN documentation explains it clearly enough. Well, better late then never... Thank you very much for pointing it out in your comment; and my 5.
—SA

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900