Global Objects not accessible in *.aspx.cs files

Discussion in 'Software' started by uriDium, Aug 13, 2007.

  1. uriDium

    uriDium

    Joined:
    Aug 13, 2007
    Messages:
    1
    Hi

    I have tried to create a global object in the global.asax file. I have a user class that i want to make global. The code for this class lives in User.cs under the app_code folder. I added an object tag in the global.asax file as such

    <object id="web_user" runat="server" class="User" scope="session" />

    I can reference web_user and all of its methods and properties as long as it is in-line in a *.aspx file. What bugs me is that i can't get to it in a code-behind fashion in the *.aspx.cs file associated with it.

    Any help will be appreciated.
    Thanks in addvance
    (Example code in C# please, my VB is not that good :frown: )
     
    uriDium, Aug 13, 2007
    #1
    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. Naga_01
    Replies:
    0
    Views:
    1,426
    Naga_01
    Jun 6, 2006
  2. Hoffa
    Replies:
    0
    Views:
    720
    Hoffa
    Oct 25, 2006
  3. Hoffa
    Replies:
    1
    Views:
    1,627
    Walter Roberson
    Oct 25, 2006
  4. Armando Ruiz

    default.aspx or login aspx?

    Armando Ruiz, Jun 22, 2004, in forum: MCAD
    Replies:
    0
    Views:
    453
    Armando Ruiz
    Jun 22, 2004
  5. getmeaditi
    Replies:
    0
    Views:
    1,741
    getmeaditi
    Mar 10, 2009
Loading...

Share This Page