Passing Details between pages

  • Thread starter Thread starter Aidan Gill
  • Start date Start date
A

Aidan Gill

Hello

I have a login screen, user types in username and
password, if they are validated I am retreiving their
email, fullname etc. I have a users.vb file with a class
that stores these details so when the user clicks the
login button the class is filled:
user.fullname = datareader.fields(1)
user.email = datareader.fields(2)


It stores the details fine. Then the user is directed to
another page, Main.aspx.
When the page loads I want to be able to grab the full
name from the above user class. It is coming back as blank

what am I doing wrong?
thanks
 
Hi,

ASP.NET is stateless. The object that you initiated for one page won’t
be available for other pages or event next page call.

You can:
1) Save the object or just those two strings in the session data. As you
get more users the memory consumption will grow.
2) Embed this data in the page form as hidden field. This data will go
to/from client every call. They can be seen by the end user and they add
K to the transfer data.

Natty Gur, CTO
Dao2Com Ltd.
28th Baruch Hirsch st. Bnei-Brak
Israel , 51114

Phone Numbers:
Office: +972-(0)3-5786668
Fax: +972-(0)3-5703475
Mobile: +972-(0)58-888377

Know the overall picture
 
Back
Top