Passing a control ViewState from a page to another

Discussion in 'ASP .Net Building Controls' started by JL, Sep 11, 2003.

  1. JL

    JL Guest

    Is it possible to keep the ViewState of a control (in Session for example)
    and apply it to a control on another page?

    Any sample would be appreciated!
    JL, Sep 11, 2003
    #1
    1. Advertising

  2. "JL" <> wrote in message
    news:...
    > Is it possible to keep the ViewState of a control (in Session for example)
    > and apply it to a control on another page?


    No. ViewState is meant to maintain the state of a control from one postback
    to another. What you seem to need is to pass the value represented by a
    control to another page so that the other page can use that value to
    populate another control.

    Session or a QueryString would be the way to go.
    --
    John Saunders
    Internet Engineer
    John Saunders, Sep 11, 2003
    #2
    1. Advertising

  3. JL

    JL Guest

    Thanks


    "John Saunders" <> wrote in message
    news:...
    > "JL" <> wrote in message
    > news:...
    > > Is it possible to keep the ViewState of a control (in Session for

    example)
    > > and apply it to a control on another page?

    >
    > No. ViewState is meant to maintain the state of a control from one

    postback
    > to another. What you seem to need is to pass the value represented by a
    > control to another page so that the other page can use that value to
    > populate another control.
    >
    > Session or a QueryString would be the way to go.
    > --
    > John Saunders
    > Internet Engineer
    >
    >
    >
    JL, Sep 11, 2003
    #3
    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. Ben Rush
    Replies:
    2
    Views:
    493
    Ben Rush
    Dec 5, 2003
  2. Reny J Joseph Thuthikattu
    Replies:
    1
    Views:
    532
    =?Utf-8?B?UHJha2FzaC5ORVQ=?=
    Dec 30, 2004
  3. Josema
    Replies:
    2
    Views:
    325
  4. Josema
    Replies:
    0
    Views:
    191
    Josema
    May 9, 2005
  5. Robert Cohen
    Replies:
    3
    Views:
    246
    Andrew Durstewitz
    Jul 15, 2003
Loading...

Share This Page