Usually using Visual Studio’s debugger is a breeze. Scanning through Locals quickly shows the values of variables, etc. However, I’m at a loss how to find out the values contained in session state variables? Can anyone give me a hand?
Let’s say I put a breakpoint right after:
Session["first_name"] = "Rob Roy";
How do I view the value contained in Session["first_name"] from locals?
It’s pretty simple to inspect the session during debug. Just put a breakpoint in your code and just highlight your
Sessioncode (eg. highlight:Session["first_name"]) then right click and selectQuickWatch....This will setup up a watch on your
Sessionfor the value you had defined. You can also inspect otherSessionelements by adjusting theExpressionfield in the QuickWatch window and clicking theReevaluatebutton.