Results 1 to 3 of 3

Thread: Declare Session level Public global variables.

  1. #1

    Thread Starter
    New Member
    Join Date
    Apr 2004
    Posts
    4

    Declare Session level Public global variables.

    Hi Folks,

    What is the best way in ASP.net to declare Session level Public global variables. So that we can access it all over our project across all web pages

    (As we used to do in in VB 6 Public Global Variables in Module.)

    Thanks.

  2. #2
    Serge's Avatar
    Join Date
    Feb 1999
    Location
    Scottsdale, Arizona, USA
    Posts
    2,744
    C#:
    Session["YourVariable"] = 10;

    VB:
    Session("YourVariable") = 10

  3. #3

    Thread Starter
    New Member
    Join Date
    Apr 2004
    Posts
    4
    Thanks Serge!!!

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width