Solved

Add a GUID value to the Session variable

Posted on 2013-06-14
2
446 Views
Last Modified: 2013-06-18
I am trying to take the value of a GUID function and add it to a session variable.  How can I do that?
0
Comment
Question by:VBBRett
2 Comments
 
LVL 12

Accepted Solution

by:
jitendra patil earned 500 total points
ID: 39249690
Hi VBRett,
try the below code.

string  g = Guid.NewGuid().ToString() ;
           Session["MyGuid"] = g;
           Response.Write("Guid Generated=>" + Session["MyGuid"].ToString());

hope this helps.
0
 

Author Comment

by:VBBRett
ID: 39250148
That's the thing.  I'm pulling the GUID from a record in the database.  I'll post the code that I have when I get home.
0

Featured Post

Gigs: Get Your Project Delivered by an Expert

Select from freelancers specializing in everything from database administration to programming, who have proven themselves as experts in their field. Hire the best, collaborate easily, pay securely and get projects done right.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Introduction Hi all and welcome to my first article on Experts Exchange. A while ago, someone asked me if i could do some tutorials on object oriented programming. I decided to do them on C#. Now you may ask me, why's that? Well, one of the re…
International Data Corporation (IDC) prognosticates that before the current the year gets over disbursing on IT framework products to be sent in cloud environs will be $37.1B.
This Micro Tutorial hows how you can integrate  Mac OSX to a Windows Active Directory Domain. Apple has made it easy to allow users to bind their macs to a windows domain with relative ease. The following video show how to bind OSX Mavericks to …
This Micro Tutorial demonstrates using Microsoft Excel pivot tables, how to reverse engineer competitors' marketing strategies through backlinks.

776 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question