AutoPostback not seeming to go to Page_load

Discussion in 'ASP .Net' started by tshad, Dec 8, 2004.

  1. tshad

    tshad Guest

    I am running a program I got off the net and found the author was doing an
    "autopostback=true" on his textbox.

    I am not sure why he was doing this as it doesn't seem to be doing anything,
    but when I put trace on, I can see the page being posted, but I have the
    following:

    *************************************************************
    private void Page_Load(object sender, System.EventArgs e)
    {
    Trace.Warn("inside Page_Load");
    if(!IsPostBack)
    ***************************************************************
    The Trace.Warn displays on all of the other Postbacks, but doesn't seem to
    on the AutoPostBack.

    Is it foregoing the Page_Load for some reason?

    I was going to take it out as it doesn't seem to be doing anything, but I am
    curious as to what it is doing.

    Thanks,

    Tom.
     
    tshad, Dec 8, 2004
    #1
    1. Advertising

  2. tshad

    Kumar Reddi Guest

    Hmm. a postback can not skip the Load event. May be you are overlooking. How
    about putting a breakpoint in the Page_Load handler and see if it does stop
    there or not.
    --
    Kumar Reddi
    http://kumarreddi.blogspot.com

    "tshad" <> wrote in message
    news:#UX$...
    > I am running a program I got off the net and found the author was doing an
    > "autopostback=true" on his textbox.
    >
    > I am not sure why he was doing this as it doesn't seem to be doing

    anything,
    > but when I put trace on, I can see the page being posted, but I have the
    > following:
    >
    > *************************************************************
    > private void Page_Load(object sender, System.EventArgs e)
    > {
    > Trace.Warn("inside Page_Load");
    > if(!IsPostBack)
    > ***************************************************************
    > The Trace.Warn displays on all of the other Postbacks, but doesn't seem

    to
    > on the AutoPostBack.
    >
    > Is it foregoing the Page_Load for some reason?
    >
    > I was going to take it out as it doesn't seem to be doing anything, but I

    am
    > curious as to what it is doing.
    >
    > Thanks,
    >
    > Tom.
    >
    >
     
    Kumar Reddi, Dec 8, 2004
    #2
    1. Advertising

  3. tshad

    tshad Guest

    "Kumar Reddi" <> wrote in message
    news:...
    > Hmm. a postback can not skip the Load event. May be you are overlooking.
    > How
    > about putting a breakpoint in the Page_Load handler and see if it does
    > stop
    > there or not.


    I thought that was what I was doing with the trace.warn statement.

    Tom.
    > --
    > Kumar Reddi
    > http://kumarreddi.blogspot.com
    >
    > "tshad" <> wrote in message
    > news:#UX$...
    >> I am running a program I got off the net and found the author was doing
    >> an
    >> "autopostback=true" on his textbox.
    >>
    >> I am not sure why he was doing this as it doesn't seem to be doing

    > anything,
    >> but when I put trace on, I can see the page being posted, but I have the
    >> following:
    >>
    >> *************************************************************
    >> private void Page_Load(object sender, System.EventArgs e)
    >> {
    >> Trace.Warn("inside Page_Load");
    >> if(!IsPostBack)
    >> ***************************************************************
    >> The Trace.Warn displays on all of the other Postbacks, but doesn't seem

    > to
    >> on the AutoPostBack.
    >>
    >> Is it foregoing the Page_Load for some reason?
    >>
    >> I was going to take it out as it doesn't seem to be doing anything, but I

    > am
    >> curious as to what it is doing.
    >>
    >> Thanks,
    >>
    >> Tom.
    >>
    >>

    >
    >
     
    tshad, Dec 8, 2004
    #3
  4. tshad

    Kumar Reddi Guest

    Placing a breakpoint and executing a programin debug mode will give you the
    ability to step into the program. Trace.warn is a just a diagnostic message
    tool, but its not equal to a breakpoint. Anyway, as i said its just another
    diagnostic tool. If you care, try placing the breakpoint and step into the
    code, rather than just relying on an output statement. I am sure you are
    missing something

    Good Luck
    --
    Kumar Reddi
    http://kumarreddi.blogspot.com


    "tshad" <> wrote in message
    news:...
    > "Kumar Reddi" <> wrote in message
    > news:...
    >> Hmm. a postback can not skip the Load event. May be you are overlooking.
    >> How
    >> about putting a breakpoint in the Page_Load handler and see if it does
    >> stop
    >> there or not.

    >
    > I thought that was what I was doing with the trace.warn statement.
    >
    > Tom.
    >> --
    >> Kumar Reddi
    >> http://kumarreddi.blogspot.com
    >>
    >> "tshad" <> wrote in message
    >> news:#UX$...
    >>> I am running a program I got off the net and found the author was doing
    >>> an
    >>> "autopostback=true" on his textbox.
    >>>
    >>> I am not sure why he was doing this as it doesn't seem to be doing

    >> anything,
    >>> but when I put trace on, I can see the page being posted, but I have the
    >>> following:
    >>>
    >>> *************************************************************
    >>> private void Page_Load(object sender, System.EventArgs e)
    >>> {
    >>> Trace.Warn("inside Page_Load");
    >>> if(!IsPostBack)
    >>> ***************************************************************
    >>> The Trace.Warn displays on all of the other Postbacks, but doesn't seem

    >> to
    >>> on the AutoPostBack.
    >>>
    >>> Is it foregoing the Page_Load for some reason?
    >>>
    >>> I was going to take it out as it doesn't seem to be doing anything, but
    >>> I

    >> am
    >>> curious as to what it is doing.
    >>>
    >>> Thanks,
    >>>
    >>> Tom.
    >>>
    >>>

    >>
    >>

    >
    >
     
    Kumar Reddi, Dec 8, 2004
    #4
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. bminder
    Replies:
    1
    Views:
    2,176
    nfedin
    Feb 23, 2004
  2. z. f.
    Replies:
    0
    Views:
    563
    z. f.
    Oct 19, 2004
  3. tshad
    Replies:
    6
    Views:
    418
    tshad
    Jan 27, 2005
  4. tshad
    Replies:
    9
    Views:
    489
    tshad
    Jun 10, 2005
  5. Novice
    Replies:
    1
    Views:
    1,153
    Mike Schilling
    Jul 19, 2003
Loading...

Share This Page