开发者

Tool (similar to Firebug) for editing session and viewstate variables real time

Does anyone have any good methodologies OR tools for editing session variables and vie开发者_开发百科wstate variables real time for ASP.NET? Every time I want to test something, I need to update my source code, recompile my application and then log in again, then navigate to the page I'm testing. It would be really efficient if there was a tool out there, similar to Firebug, where you can change a variable and see the outcome immediately. Am I dreaming or is there such a thing? If not, is there something that shows me a nice easily readable representation of the session variables and viewstate?


Session variables are stored on server. There is no way you can view/tweak them in the browser.

Viewstate on the other hand can be decoded. Here's an online decoder: http://lachlankeown.blogspot.com/2008/05/online-viewstate-viewer-decoder.html

However, modifying it is tricky and .Net guards against tampering.

But then, Session/Viewstate are not like dom/script/css elements where you may want to tweak one or two settings and fix the issue. Tweaking them is not going to be easy, nor is it going to server the same purpose/benefit.

Let me know if I'm overlooking something.


If you can edit the html of the aspx page on the server then just set Trace="true" in the @Page directive as below:

<%@ Page Language="C#" Trace="true"  MasterPageFile="~/SiteAdmin.master"  AutoEventWireup="true" CodeFile="AddEditProfile.aspx.cs" Inherits="AddEditProfile" %>

Then when you load the page in the browser you will see a lot of information about the page when you scroll down to the bottom of it, including the session variable names and values.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜