共用方式為


VS 2003 Tip #5: Intellisense in the immediate window

Ok, one other new feature we added was to add intellisense to the immediate window.

The immediate window is a window used to evaluate expressions, much like the VB6 one. When debugging and in break mode, you can open it up from Debug->Windows->Immediate. Then type in the expression you need evaluated and voilà, it returns values. Ok, one of the big changes in Everett was that we added intellisense dropdowns to the immediate window so you could just type for e.g. this. and then get a nice dropdown to see the members on the object. So you don't have to type into the watch window to see evaluations, or mistype into it by mistake.

Which brings me to another feedback point. How important is this to you, Mr. C# Developer? VB.NET was the primary customer for this feature in VS2003 - do you happen to use this also? Anyone? Let us know.

Comments

  • Anonymous
    March 01, 2004
    Being an ex VB developer I missed having intellisense in the Immediate windows, even when coding in C#...:-)
  • Anonymous
    March 01, 2004
    Take it out! Dont you know that use of an interactive debugger is an admission of failure to any self-respecting C# programmer!? :-)
  • Anonymous
    March 01, 2004
    I use the immediate window every day and so do most of my co-workers (although for some odd reason intellisense has stopped working for one guy).

    Having intellisense, even if it is just to create little statements in the immediate window, is great. Now all we need is stop and go debugging hint hint

    :)
  • Anonymous
    March 01, 2004
    The comment has been removed
  • Anonymous
    March 01, 2004
    I use it quite a lot - especially when I'm learning about a bit of the framework new to me, or a 3rd party app of some kind. Very useful!
  • Anonymous
    March 01, 2004
    The comment has been removed
  • Anonymous
    March 01, 2004
    I always use it. It's something I missed a lot in VS.NET 2002 since I moved from VB6 to C#.
    I still use and love it, but what I'm getting in my working environment is that about 30% of programmers use the Immediate window and 70% use Watch windows.
  • Anonymous
    March 01, 2004
    I'm definitely liking the Immediate window. I'm not totally in the habit of using it yet, but when I do remember to use it, it's a lot more convienent than using the Watch window for this sort of thing.
  • Anonymous
    March 01, 2004
    I completely agree, I use it all the time and want to see it in future versions.
  • Anonymous
    March 01, 2004
    I use it in about 70% of my debugging sessions. Sometimes it's not capable of doing what I want (method evaluation doesn't seem to work very well), but it looks like Whidbey's on the right track.
  • Anonymous
    March 01, 2004
    I enjoy the immediate window from VB6, but I find the one for the VS.NET environment lacking, at best. The evaluation expression doesn't seem to be very good (as one other poster said), and I miss the ability to cut and paste within the same window.

    Basically, I liked the fact that the VB6 version was like a magic notepad. I could cut and paste at will. I don't like cycling through what I had when I press the up arrow key.

    However, the inclusion of intellisense will have me give the feature a second try.

    Overall though, I prefer to use the watch window because of these omissions.
  • Anonymous
    March 01, 2004
    I use and love the Immediate window, even more now that it has intellisense.
  • Anonymous
    March 02, 2004
    Intellisense for the C# immediate window would be great.

    I'm working on a huge solution, and the compile-and-run cycle on my machine usually takes about 2 minutes (I timed it at 5 minutes 30 seconds when I changed some code in the bottom layer).

    In other words, recompiling is extremely expensive in terms of time. When I'm trying to figure out vaguely documented framework classes and methods (XML parsing and WMI come to mind), the immediate window lets me figure out the framework items in question by trying different things on our data without the expensive recompile.

    Now if we only had edit-and-continue, I could tweak the visual look of a custom control in the bottom layer of our app, and see how it looked in our app without the 5-minute recompile-and-run cycle.
  • Anonymous
    March 02, 2004
    The comment has been removed
  • Anonymous
    March 02, 2004
    I use it all the time!
  • Anonymous
    March 02, 2004
    I love this feature. Now PLEASE, PLEASE, PLEASE add edit and continue to C# like VB.NET team is doing!!! Just tell the product manager "ROI and TCO." ;-)
  • Anonymous
    March 02, 2004
    I frequently use it. In fact, I've got so used to intellisense that I get disappointed when it doesn't work when I'm typing in the watch window :-)
  • Anonymous
    March 03, 2004
    "Just tell the product manager "ROI and TCO." ;-) " -- now that would probably matter if they ate their own dog food and used VS.NET to build anything beyond trivial quickstart examples.
  • Anonymous
    March 07, 2004
    Are you Kidding! This feature is great, saves a lot of time and effort. I was glad not to lose this when I moved from VB to C#.
  • Anonymous
    March 08, 2004
    I would find this incredibly usefull, except that property evaulation / method invocation is very likely to cause debugger deadlocks inside my app (perhaps due to our heavy use of AppDomains?).

    Microsoft support says this is a known issue and has been fixed in Whidbey. Since it does work fine 75%-90% of the time, I still occasionally risk using it when necessary - it is still an invaluable feature! I just wish there was a hotfix for this bug so that I could actually rely on this feature on a regular basis.
  • Anonymous
    March 08, 2004
    Any way to get the immediate window to understand cast objects?
  • Anonymous
    March 13, 2004
    I use both the Watch Window and the Immediate Window together, interchangibly. The Watch window is good when I want to, umm, WATCH something. The immediate window is for when I want to get at properties nested deep inside - I use it because of the Intellisense.

    In short, anything that has intellisense is good and will be used, end of story. :)
  • Anonymous
    March 24, 2004
    This feature was a welcome surprise, please keep it around.

    ~Ms. C# developer
    ;)
  • Anonymous
    June 07, 2008
    Ok, one other new feature we added was to add intellisense to the immediate window. The immediate window is a window used to evaluate expressions, much like the VB6 one. When debugging and in break mode, you can open it up from Debug->Windows->Immediate