Question on Sessions variables

Discussion in 'ASP .Net' started by jty202, Jan 17, 2005.

  1. jty202

    jty202 Guest

    1. Can I have an array of objects as sessions variable in other words
    sessions array-of-objects? If so how?

    2. Besides Sessions variable what else can I use to store large amount of
    data temporarily thats related to the current user.
    ( can I use temp files? and instead of storing the large text data in a
    sessions variable or arrays, I could store the temp-file names which
    contains the large text data? )
     
    jty202, Jan 17, 2005
    #1
    1. Advertising

  2. jty202

    Matt Berther Guest

    Hello jty202,

    How long do you need to store it? If its per request, you could look at the
    HttpContext.Current.Items collection.

    --
    Matt Berther
    http://www.mattberther.com

    > 1. Can I have an array of objects as sessions variable in other words
    > sessions array-of-objects? If so how?
    >
    > 2. Besides Sessions variable what else can I use to store large amount
    > of
    > data temporarily thats related to the current user.
    > ( can I use temp files? and instead of storing the large text data in
    > a
    > sessions variable or arrays, I could store the temp-file names which
    > contains the large text data? )
     
    Matt Berther, Jan 17, 2005
    #2
    1. Advertising

  3. Hi,

    A session variable can pretty much take whatever you throw at it. I'd maybe
    consider creating an array of objects and putting it in a session variable,
    rather than the other way around. I have never tried that before, as I try
    to avoid session variables if possible.

    On your second point, for years developers have been looking for an
    alternative to session variables. This article discusses a method using a
    guid and a database. http://www.4guysfromrolla.com/webtech/041600-2.shtml

    Good luck,

    Regards,

    Stuart
    MCSD, MCT


    "jty202" <> wrote in message
    news:uTOPjsN$...
    > 1. Can I have an array of objects as sessions variable in other words
    > sessions array-of-objects? If so how?
    >
    > 2. Besides Sessions variable what else can I use to store large amount of
    > data temporarily thats related to the current user.
    > ( can I use temp files? and instead of storing the large text data in a
    > sessions variable or arrays, I could store the temp-file names which
    > contains the large text data? )
    >
    >
    >
    >
     
    Stuart A Hill, Jan 17, 2005
    #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. Ken Cox [Microsoft MVP]

    Re: Relationship between IIS Sessions and ASP.NET Sessions?

    Ken Cox [Microsoft MVP], Aug 8, 2003, in forum: ASP .Net
    Replies:
    1
    Views:
    5,398
    Luther Miller
    Aug 8, 2003
  2. Replies:
    9
    Views:
    988
  3. Jacques Oberto

    Variables in multiple sessions

    Jacques Oberto, Oct 1, 2009, in forum: ASP .Net
    Replies:
    15
    Views:
    530
    Scott M.
    Oct 2, 2009
  4. scottymo
    Replies:
    3
    Views:
    731
    Dominick Baier
    Sep 30, 2006
  5. Bookham Measures

    Moving from ASP Sessions to Database Sessions

    Bookham Measures, Jul 23, 2007, in forum: ASP General
    Replies:
    19
    Views:
    584
    Bookham Measures
    Aug 23, 2007
Loading...

Share This Page