Logo 
Search:

Asp.net Forum

Ask Question   UnAnswered
Home » Forum » Asp.net       RSS Feeds

Maintain User Control State on different Pages

  Asked By: Daisy    Date: Dec 19    Category: Asp.net    Views: 1525
  

I have a reporting application which has common selection criteria that
is
To appear on multiple "reporting" pages.

I now want to design a common usercontrol on each reporting page and
persist the selection criteria values when I use a tab menu to jump to
different report pages. This way a user would only enter the criteria
once when switching between pages.

1. I could use a session variable for each criteria field and populate
the
user control from those fields.

2. ViewState: Since I'm not posting back to the same page I can't use
view state.

3. Querystring: there are up to 6 parameters to pass, this seems
unwieldly.

Share: 

 

3 Answers Found

 
Answer #1    Answered By: Elaine Stevens     Answered On: Dec 19

I'm using the IE Webcontrols:

www.asp.net/.../Download.aspx?tabindex=0&tabid=1

I use a tabstrip linked with a multipage. What's nice about it is
it will keep everything in viewstate  for you, so you can flip
between tabs and keep the same information you filled out or
modified on that tab.

1. session  variables take up server memory. They can work, but
remember not to shove tons into session variables. Manage your
session well.

2. True, viewstate dies if not posting back  to the same page  (from
what I've experienced). I believe you can maintain viewstate across
different pages  though if you make sure it is enabled on every page
and every control. It should be...

3. That's the old way. If anything, use viewstate, then session,
then querystring. querystring  is good to directly pass  variables to
a specific page directly. It depends here. I don't know how much
data you're putting in the querystring. Look at Yahoo!. They put
tons of stuff in the querystring.

 
Answer #2    Answered By: Alexis Castillo     Answered On: Dec 19

I believe the Web Controls require IE 5.5 of higher.
I'm not sure everyone is there....

I'm thinking of 1 session  variable with all the fields  separated by a
"|"
Thus the user  control will populate the selection  criteria from the
parsed session field.

 
Answer #3    Answered By: Dot net Sachin     Answered On: Dec 19

The Webcontrols do not require a browser. THey work clientside in IE 6 and
they postback in other browers but they do indeed work in all browesre even
ones that do not support client scripting at all.

www.eraserver.net/minh/wccompare/control_tabs.asp
shows screenshots in many browsers.....

 
Didn't find what you were looking for? Find more on Maintain User Control State on different Pages Or get search suggestion and latest updates.




Tagged: