|
web
newsgroups
|
|||||||||||||||||||||||
|
|||||||||||||||||||||||
Debugging in VS2005 - why is some code shaded grey?I see this when I'm stepping through in the debugger ... just thought I'd
ask, and I just know it's going to be one of those "Doh" moments, but it's got me foxed just now. "Andrew Kidd" <andrew@nospam.com> wrote in message What kind of project, and which language?news:uerihYeEGHA.212@TK2MSFTNGP10.phx.gbl... >I see this when I'm stepping through in the debugger ... just thought I'd >ask, and I just know it's going to be one of those "Doh" moments, but it's >got me foxed just now. > When I debug C++ or C# code, the comments are grayed, but no other statements. Can you give an example of a grayed statement in the code you're debugging? "Andrew Kidd" <andrew@nospam.com> wrote in message Please disregard part of my previous. I'm not awake yet (obviously). You're news:uerihYeEGHA.212@TK2MSFTNGP10.phx.gbl... >I see this when I'm stepping through in the debugger ... just thought I'd >ask, and I just know it's going to be one of those "Doh" moments, but it's >got me foxed just now. using VB. Still. an example of a grayed statement would be useful. I know that feeling ... ;-) ... I don't mean the colour of the text in the
code window, I mean the background (see the attached example). If I set the breakpoint to the Try of a Try ... Catch block, then the Catch statements have their background colour set to grey ... ??? Show quoteHide quote "pvdg42" <pvdg42@newsgroups.nospam> wrote in message [attached file: debugger-2.jpg]news:%23arngYfEGHA.3004@TK2MSFTNGP15.phx.gbl... > > "Andrew Kidd" <andrew@nospam.com> wrote in message > news:uerihYeEGHA.212@TK2MSFTNGP10.phx.gbl... >>I see this when I'm stepping through in the debugger ... just thought I'd >>ask, and I just know it's going to be one of those "Doh" moments, but it's >>got me foxed just now. > Please disregard part of my previous. I'm not awake yet (obviously). > You're > using VB. > Still. an example of a grayed statement would be useful. > > Isn't that just to indicate the block of code matching up with the
selected line (in this case "Try")? I would expect the same behavior for If ... Then, For ... Next, etc? /Joergen Bech Show quoteHide quote On Thu, 5 Jan 2006 14:58:12 -0000, "Andrew Kidd" <andrew@nospam.com> wrote: >I know that feeling ... ;-) ... I don't mean the colour of the text in the >code window, I mean the background (see the attached example). > >If I set the breakpoint to the Try of a Try ... Catch block, then the Catch >statements have their background colour set to grey ... ??? > > >"pvdg42" <pvdg42@newsgroups.nospam> wrote in message >news:%23arngYfEGHA.3004@TK2MSFTNGP15.phx.gbl... >> >> "Andrew Kidd" <andrew@nospam.com> wrote in message >> news:uerihYeEGHA.212@TK2MSFTNGP10.phx.gbl... >>>I see this when I'm stepping through in the debugger ... just thought I'd >>>ask, and I just know it's going to be one of those "Doh" moments, but it's >>>got me foxed just now. >> Please disregard part of my previous. I'm not awake yet (obviously). >> You're >> using VB. >> Still. an example of a grayed statement would be useful. >> >> > > Hi Joergen ... that's what I'm suspecting, just wanting confirmation as I
couldn't find anything in the documentation. Show quoteHide quote "Joergen Bech @ post1.tele.dk>" <jbech<NOSPAMNOSPAM> wrote in message news:lreqr1pmclu4rhp7a8fpvj7v0l1foopffj@4ax.com... > > Isn't that just to indicate the block of code matching up with the > selected line (in this case "Try")? > > I would expect the same behavior for If ... Then, For ... Next, etc? > > /Joergen Bech > > > > On Thu, 5 Jan 2006 14:58:12 -0000, "Andrew Kidd" <andrew@nospam.com> > wrote: > >>I know that feeling ... ;-) ... I don't mean the colour of the text in the >>code window, I mean the background (see the attached example). >> >>If I set the breakpoint to the Try of a Try ... Catch block, then the >>Catch >>statements have their background colour set to grey ... ??? >> >> >>"pvdg42" <pvdg42@newsgroups.nospam> wrote in message >>news:%23arngYfEGHA.3004@TK2MSFTNGP15.phx.gbl... >>> >>> "Andrew Kidd" <andrew@nospam.com> wrote in message >>> news:uerihYeEGHA.212@TK2MSFTNGP10.phx.gbl... >>>>I see this when I'm stepping through in the debugger ... just thought >>>>I'd >>>>ask, and I just know it's going to be one of those "Doh" moments, but >>>>it's >>>>got me foxed just now. >>> Please disregard part of my previous. I'm not awake yet (obviously). >>> You're >>> using VB. >>> Still. an example of a grayed statement would be useful. >>> >>> >> >> > Hi Andrew,
Have you stepped through the list in your Fonts and Colors settings to see what's back-shaded gray? I've got several things that are. If you're not sure which it is, try changing the items to some bright color one-by-one and see if that shows up in your code. -- Show quoteHide quoteCindy Winegarden MCSD, Microsoft Visual FoxPro MVP cindy_winegar***@msn.com www.cindywinegarden.com "Andrew Kidd" <andrew@nospam.com> wrote in message news:uerihYeEGHA.212@TK2MSFTNGP10.phx.gbl... >I see this when I'm stepping through in the debugger ... just thought I'd >ask, and I just know it's going to be one of those "Doh" moments, but it's >got me foxed just now. > Turns out it's tied to the "Visual Basic Read Only Marker" in the Options >
Fonts and Colors > Display items dialog, which makes sense since, as Matt said, it can't be edited during debugging. -- Show quoteHide quoteCindy Winegarden MCSD, Microsoft Visual FoxPro MVP cindy_winegar***@msn.com www.cindywinegarden.com "Cindy Winegarden" <cindy_winegar***@msn.com> wrote in message news:%23YyakEjEGHA.3468@TK2MSFTNGP15.phx.gbl... > Hi Andrew, > > Have you stepped through the list in your Fonts and Colors settings to see > what's back-shaded gray? In VB2005, Edit and Continue is finally possible while debugging. Code which is grey cannot be edited during debugging (because it would require a total recompilation of the project for whatever reason -- public method, exception handler redirection, etc.) -- that's all it means.
Hope this helps! --Matt Gertz--* VB Compiler Dev Lead -----Original Message----- From: Andrew Kidd Posted At: Thursday, January 05, 2006 2:53 AM Posted To: microsoft.public.dotnet.languages.vb Conversation: Debugging in VS2005 - why is some code shaded grey? Subject: Debugging in VS2005 - why is some code shaded grey? I see this when I'm stepping through in the debugger ... just thought I'd ask, and I just know it's going to be one of those "Doh" moments, but it's got me foxed just now. Apart from your kind repply, Matt...
I'd like to say that's great that developers from MS are actually exchanging thoughts with the developer community. It's a wonderful thing being able to interact with the real people who develops the tools we use. Thanks... PJ http://pjondevelopment.50webs.com/ I must assure you that it's a two-way street :-). It's fun to code up a language and language services, particularly one which has as wide a reach as VB, but it's impossible to predict all of the billions of ways that customers are going to use it, and without the customer contact, we developers tend to get a little isolated from customers and the directions that they want to head. There's certainly been more than one occasion where Product Support has handed us a customer bug and we've scratched our heads and thought "Oh, cool idea, but who knew that customers were going to need to use the product *that* way?" Ergo, for the past 3 or so years, we've been trying to build up a better presence on the newsgroups, forums, and blogs so that we can help people get the most out of the product, but almost more importantly to get a better idea what people need.
Have you checked out the forums at http://forums.microsoft.com? A lot of MS folk hang out there as well (including me), and the only reason I don't additionally have a blog that 90% of what I do each day would be utterly tedious to read. ("Triaged 54 bugs today, attended Divisional Tactics meeting to plan milestone exit criteria, verified that VB was on track to meet stepdown goals for known code defects" ... yawn...) --Matt--* -----Original Message----- From: PJ on Development Posted At: Thursday, January 05, 2006 11:22 PM Posted To: microsoft.public.dotnet.languages.vb Conversation: Debugging in VS2005 - why is some code shaded grey? Subject: Re: Debugging in VS2005 - why is some code shaded grey? Apart from your kind repply, Matt... I'd like to say that's great that developers from MS are actually exchanging thoughts with the developer community. It's a wonderful thing being able to interact with the real people who develops the tools we use. Thanks... PJ http://pjondevelopment.50webs.com/ Thanks for clearing that up. I hadn't noticed it before.
Very useful. After a long time with VS2003 I had gotten used to NOT having edit'n'continue, so I hardly ever use it, even though it is there now. Did not make the connection. Regards, Joergen Bech On Thu, 05 Jan 2006 15:52:03 -0800, Matthew.Ge***@feedback.microsoft.com wrote: Show quoteHide quote >In VB2005, Edit and Continue is finally possible while debugging. Code which is grey cannot be edited during debugging (because it would require a total recompilation of the project for whatever reason -- public method, exception handler redirection, etc.) -- that's all it means. > >Hope this helps! > --Matt Gertz--* > VB Compiler Dev Lead > >-----Original Message----- >From: Andrew Kidd >Posted At: Thursday, January 05, 2006 2:53 AM >Posted To: microsoft.public.dotnet.languages.vb >Conversation: Debugging in VS2005 - why is some code shaded grey? >Subject: Debugging in VS2005 - why is some code shaded grey? > > >I see this when I'm stepping through in the debugger ... just thought I'd >ask, and I just know it's going to be one of those "Doh" moments, but it's >got me foxed just now. |
|||||||||||||||||||||||