User-defined object with session scope

  • Thread starter Simon Niederberger
  • Start date
A

Aaron [SQL Server MVP]

How can I give a user-defined object session scope?

For what possible purpose? A database is a much better and more scalable
place to maintain state.

Have you read http://www.aspfaq.com/2053 and the references it guides you
to?
 
S

Simon Niederberger

Actually, I have an ASP script which generates an object which attributes
are used as predefined values in a form. The user can then choose to use
these suggestions o overwrite them with his own values. As we're developing
the entire site using VBS objects, I would have liked the script the
generate a "proposal" object, put that in session scope, and on the next
page read that object and populate the form fields.

I guess, with VBS objects in session scope being essentially not available
(funny enough, J2EE server easily do the task!), I'll either go with putting
each attribute as simple session variable or merging the object generating
script with the form, thereby violating the MVC pattern, but well, this
isn't university, it actually has to work ;-)

thanx anyway
simon
 
M

Mark Schupp

Have your object persist its data into a session variable when destroyed and
reload from the session variable when created (or include separate load and
save methods).

--
Mark Schupp
Head of Development
Integrity eLearning
www.ielearning.com
 

Ask a Question

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

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
474,159
Messages
2,570,879
Members
47,417
Latest member
DarrenGaun

Latest Threads

Top