OK. I'll continue to followup in your "explanation of when need..." issue.
Please feel free to post there.
Thanks,
Steven Cheng
Microsoft Online Support
Get Secure!
www.microsoft.com/security (This posting is provided "AS IS", with no warranties, and confers no
rights.)
--------------------
| From: "TS" <manofsteele1@nospam.nospam>
| References: <#McrIf4lFHA.3380@TK2MSFTNGP10.phx.gbl>
<OvLXmC5lFHA.2904@tk2msftngp13.phx.gbl>
<eqErbF5lFHA.2916@TK2MSFTNGP14.phx.gbl>
<ueXTvQ5lFHA.2852@TK2MSFTNGP15.phx.gbl>
<ODm5H15lFHA.3256@TK2MSFTNGP12.phx.gbl>
<ea4lTR6lFHA.1464@TK2MSFTNGP14.phx.gbl>
<0xRSN28lFHA.940@TK2MSFTNGXA01.phx.gbl>
| Subject: Re: processing postback
| Date: Fri, 5 Aug 2005 08:34:54 -0500
| Lines: 848
| X-Priority: 3
| X-MSMail-Priority: Normal
| X-Newsreader: Microsoft Outlook Express 6.00.2800.1158
| X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1165
| Message-ID: <O3JE4JcmFHA.3256@TK2MSFTNGP12.phx.gbl>
| Newsgroups: microsoft.public.dotnet.framework.aspnet.buildingcontrols
| NNTP-Posting-Host: 103nat100.tea.state.tx.us 198.214.103.100
| Path: TK2MSFTNGXA01.phx.gbl!TK2MSFTNGP08.phx.gbl!TK2MSFTNGP12.phx.gbl
| Xref: TK2MSFTNGXA01.phx.gbl
microsoft.public.dotnet.framework.aspnet.buildingcontrols:4000
| X-Tomcat-NG: microsoft.public.dotnet.framework.aspnet.buildingcontrols
|
| thanks, but it seems my only problem that still exists is the posts i'm
| making in "explanation of when need..."
|
|
[quoted text, click to view] | "Steven Cheng[MSFT]" <stcheng@online.microsoft.com> wrote in message
| news:0xRSN28lFHA.940@TK2MSFTNGXA01.phx.gbl...
| > Hi TS,
| >
| > Welcome to ASPNET newsgroup.
| > Regarding on the post back event handling problem in composite control,
| > generaly speaking , the most likely cause is still the event handler's
| > registering sequence and the control's constructing and adding approach.
| >
| > For your former problem, (postback event for sub controls not fire when
| the
| > composite control doesn't implement INamingContainer), this is because
for
| > sub controls contained in composite control, they need to be assigned an
| > unique clientID which will be used when it's postback event be fired(
the
| > runtime will use this ID to mapping the event to the correct control
| > instance). When we didn't implement NamingContainer interface, the
| > composite control won't assign the appropriate ClientID(also UniqueID)
for
| > the nested sub controls, so sub controls' post back event won't be
handled
| > correclty.
| >
| > As for the new problem you mentioned, I'm wondering how did you create
| your
| > composite control (also its nested sub composite controls inside it)?
For
| > the "Page" property, it'll be assigned properly when a certain control
is
| > added into its container control's Controls collection, we don't need to
| > manually assign it. Anyway, would you try provide some code snippet to
| > represent your composite control's code logic? It'll be much helpful if
| you
| > can make a very simple repro demo control to demostrate the problem.
| >
| > Thanks,
| >
| > Steven Cheng
| > Microsoft Online Support
| >
| > Get Secure!
www.microsoft.com/security | > (This posting is provided "AS IS", with no warranties, and confers no
| > rights.)
| >
| >
| >
| >
| >
| >
| > --------------------
| > | From: "TS" <manofsteele1@nospam.nospam>
| > | References: <#McrIf4lFHA.3380@TK2MSFTNGP10.phx.gbl>
| > <OvLXmC5lFHA.2904@tk2msftngp13.phx.gbl>
| > <eqErbF5lFHA.2916@TK2MSFTNGP14.phx.gbl>
| > <ueXTvQ5lFHA.2852@TK2MSFTNGP15.phx.gbl>
| > <ODm5H15lFHA.3256@TK2MSFTNGP12.phx.gbl>
| > | Subject: Re: processing postback
| > | Date: Tue, 2 Aug 2005 15:54:05 -0500
| > | Lines: 717
| > | X-Priority: 3
| > | X-MSMail-Priority: Normal
| > | X-Newsreader: Microsoft Outlook Express 6.00.2800.1158
| > | X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1165
| > | Message-ID: <ea4lTR6lFHA.1464@TK2MSFTNGP14.phx.gbl>
| > | Newsgroups:
| >
|
microsoft.public.dotnet.framework.aspnet.buildingcontrols,microsoft.public.d
| > otnet.framework.aspnet.webcontrols
| > | NNTP-Posting-Host: 103nat100.tea.state.tx.us 198.214.103.100
| > | Path: TK2MSFTNGXA01.phx.gbl!TK2MSFTNGP08.phx.gbl!TK2MSFTNGP14.phx.gbl
| > | Xref: TK2MSFTNGXA01.phx.gbl
| > microsoft.public.dotnet.framework.aspnet.webcontrols:10237
| > microsoft.public.dotnet.framework.aspnet.buildingcontrols:3976
| > | X-Tomcat-NG: microsoft.public.dotnet.framework.aspnet.buildingcontrols
| > |
| > | I have a new issue:
| > |
| > | One of my controls in my composite control is in itself a composite
| > control.
| > | It has an event that is raised when one of its drop down lists
selected
| > | index changes. In main composite control, i hook into this other
| control's
| > | event so that i can do processing. This event won't fire in either the
| > drop
| > | down list's selected index change event handler and also not in the
| event
| > | handler that my main control subscribes to.
| > |
| > | I have a clue that may be the reason: In this sub composite control,
it
| > | tries to access the page property, which is null when it's
| > | CreateChildControls. So how i fixed it was to assign this composite
| > | control's page property to my main control's page property so that it
| now
| > | can access the page property. I'm wondering if this has something to
do
| > with
| > | the event not firing.
| > |
| > | thanks
| > |
[quoted text, click to view] | > | "TS" <manofsteele1@nospam.nospam> wrote in message
| > | news:ODm5H15lFHA.3256@TK2MSFTNGP12.phx.gbl...
| > | > I figured it out, i wasnt' implementing INamingContainer. that fixes
| > | > it...BUT WHY DOES THIS IMPACT IF EVENTS GET FIRED OR NOT????
| > | >
| > | >
[quoted text, click to view] | > | > "TS" <manofsteele1@nospam.nospam> wrote in message
| > | > news:ueXTvQ5lFHA.2852@TK2MSFTNGP15.phx.gbl...
| > | > > I think i maybe should be doing this at all because i can just
| access
| > | the
| > | > > control's value because that control handles the functionality
| > | > automatically
| > | > > that I was trying to do.
| > | > >
| > | > > If this is so, then i still have a problem: How do i raise events
in
| > my
| > | > > control for controls i have created in createchildcontrols? I have
| the
| > | > > controls wired up to event handlers, but they are never hit.
| > | > >
| > | > > What do i need to do?
| > | > >
| > | > > thanks
| > | > >
[quoted text, click to view] | > | > > "TS" <manofsteele1@nospam.nospam> wrote in message
| > | > > news:eqErbF5lFHA.2916@TK2MSFTNGP14.phx.gbl...
| > | > > > i followed the article at:
| > | > > >
| > | > >
| > | >
| > |
| >
|
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/cpguide/htm
| > l/cpconpostbackdataprocessingsample.asp
| > | > > > and it works like that except like i said when I use
| > | createchildControls
| > | > > > instead of render (because i need to render multiple controls),
it
| > | > doesn't