Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsFree MagazinesWhite PapersSubmit Content
Discussion GroupsASP.NETWindows FormsLanguages.NET FrameworkVisual Studio.NET
Articles.NET FrameworkASP.NETToolsWindows Forms
.NET DirectoryOpen Source ProjectsUser GroupsWeb Resources
Related Topics
Visual Basic 6SQL ServerMS AccessOther DB ProductsMS Server ProductsMore Topics ...

.NET Forum / ASP.NET / General / December 2007

Tip: Looking for answers? Try searching our database.

SessionID -> UserId Insert and View

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Jim - 27 Nov 2007 17:34 GMT
Using either EW or VSE2008, I want to have a GridView that will:
- Insert the logged in user's UserId from either the User table or the
membership table when the user inserts a record.
- When the user views the GridView, only their records are shown.  I don't
want to use a query string that uses the UserID for securtiy resons, so I'm
thinking that I can use a SessionID that is tied to the UserId?

Requests:
1. Insert a record that will automatically insert UserId
2. View reords in GridView that belong to the logged in user with SessionID

I'm not sure what all I need to do to get the SessionID working?  I have put
"<sessionState mode="InProc" cookieless="false" timeout="20" />" into my
web.config file.
But now what?

Thank you for any help.
Peter Bromberg [C# MVP] - 27 Nov 2007 20:56 GMT
It sounds like you just want to store the UserID in a Session variable, e.g.
Session["userId"]=UserID;

--Peter
"Inside every large program, there is a small program trying to get out."
http://www.eggheadcafe.com
http://petesbloggerama.blogspot.com
http://www.blogmetafinder.com

> Using either EW or VSE2008, I want to have a GridView that will:
> - Insert the logged in user's UserId from either the User table or the
[quoted text clipped - 13 lines]
>
> Thank you for any help.
Jim - 27 Nov 2007 21:29 GMT
Thanks for the reply, but I'm not sure what to do with this.
Where do I put this string?

I'm coding in VB ASP.NET.

Thanks.
> It sounds like you just want to store the UserID in a Session variable,
> e.g.
[quoted text clipped - 27 lines]
>>
>> Thank you for any help.
Jim - 03 Dec 2007 23:05 GMT
Peter -
Can you explain in further detail how to use this Session["userId"]=UserID
in VB?
1. What need to be in the web.config file
2. What would the aspx page need?
3. What would the aspx.vb page need?

Thank you for this.  I have tried to Google the string and didn't come up w/
anything.

> It sounds like you just want to store the UserID in a Session variable,
> e.g.
[quoted text clipped - 27 lines]
>>
>> Thank you for any help.

Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.