Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Session Values - Multiple Projects in Solution... 1

Status
Not open for further replies.

jzelhart

Programmer
Feb 10, 2003
469
US
Ok I am trying to break a larger solution into projects (multiple tier development and multiple software groupings) I had this working when the presentation tier was all in one project. I used Sessions to pass some small things needed in the next page. When I broke this into multiple projects this theory broke.

Are there other ways to do this?

Should I keep all the presentation tier in one project (could be really big)?

Hope everyone is having a great day!

Thanks - Jennifer
 
Other ways to pass values to page include:

Querystring
Database storage
Cookie storage

There is no solid answer to whether or not your presentation layer should be kept in a single project. Normally, the answer is yes, but there are certainly situations where any heuristic doesn't hold true.

An extra large project may be one because you may have certain portions of the site under development while others are ready for publish. This is a huge pain in ASP.NET V1.x, which is supposed to go away in v2.

It may, however, make sense to keep it all in one to overcome problems like this. It's nearly impossible for someone here to answer that question, especially given the relatively small amount of info known.

-p

penny.gif
penny.gif

The answer to getting answered -- faq855-2992
 
Thanks link9, as usual you are very helpful.

I was just looking for some input. I may also look into the Database Storage theory.

Hope everyone is having a great day!

Thanks - Jennifer
 
If you want to access the response, request, session etc from another project you can use the httpcontext.current object. For example you can use (from a seperate project)

Dim username as string = httpcontext.current.session("user")

Hope this helps

S.
 
shatch,

I get a null when I reference the session value from another project. But it works fine in one project.

Can you show me the code that you used to make it work for you?

Hope everyone is having a great day!

Thanks - Jennifer
 
Just a quick update...

I did decide to do multiple projects for various reasons, but I store the data that I needed in the database and pass a User and Key in the Response.Redirect strings. I use the User to call up the stored data and the Key to verify that the person logged in today and the the Key and User match up. I didn't want a user to just change the User to someone with more access etc.

Thanks for the help.

Hope everyone is having a great day!

Thanks - Jennifer
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top