debugging

Windbg help -> how can I read the code at this callstack?

Hi folks, I have a dump of a windows service i made. The exception is that my code can't move a file (for some reason). Now, in my code there's a number of places where i move files around the filesystem. So, using Windbg, i'm trying to see the code where the exception occurs. here's my !clrstack dump.. 0:016> !clrstack -p OS Threa...

Where does Console.WriteLine go in Debug?

I found this question, but what I want to know is different - does the output from Console.WriteLine go anywhere when debugging? I know that for it to go to the output window I should should Debug.WriteLine() or other methods, but where does the standard Console.WriteLine() go? Edit When debugging, you don't see the black console window...

break whenever a file (or class) is entered

In Visual Studio, is there any way to make the debugger break whenever a certain file (or class) is entered? Please don't answer "just set a breakpoint at the beginning of every method" :) I am using C#. ...

How do I print the elements of a C++ vector in GDB?

I want to examine the contents of a std::vector in GDB, how do I do it? Let's say it's a std::vector<int> for the sake of simplicity. ...

Debugging crash and memory leak

Hi, We are developing a plugin for outlook in visual basic 6.0.We have been facing issues like outlook crash ( due to some objects not getting destroyed or some other reason). One way we have been solving this issue is reading code,commenting code( to observe the affect), logging etc. Are there any other ways of debugging? Are there too...

SSIS Debugging Performance

I’m using SSIS to synchronize data between two databases. I’ve used SSIS and DTS in the past, but I generally write an application for things of this nature (I’m coder and it just comes easier to me). In my package I use a SQL Task that returns about 15,000 rows. I’ve hooked that up to a Foreach Container, and within that I assign the r...

How to run an ASP.NET application with verbose debug messages of the ASP.NET runtime

How do I configure an ASP.NET application to write verbose log messages of what ASP.NET engine itself is doing. What I get with <trace enabled="true" pageOutput="false" requestLimit="10000" writeToDiagnosticsTrace="true"/> is just as much as [2488] aspx.page: Begin PreInit [2488] aspx.page: End PreInit [...

Javascript debuggers for low-marketshare browsers

I am working on a web application that needs to support the widest possible audience. I have errors popping up in Konqueror that don't occur in major browsers. So I'm curious, are there any JavaScript (or CSS for that matter) debugging tools for any low-market share browsers, or is there some platform agnostic way to ensure proper execu...

Debugging is a bad smell - how to persuade them ?

I've been working on a project that can't be described as 'small' anymore (40+ months), with a team that can't be defined as 'small' anymore (~30 people). We've been using Agile/Scrum (1) practices all along, and a healthy dose of TDD. I'm not sure if I picked this up from Agile or TDD, more likely a combination of the two, but I'm now ...

How do I keep the development web server (Cassini) running in Visual Studio 2008?

I'm using Visual Studio 2008 to develop ASP.NET applications. Currently I'm debugging with running on IIS. I would like to switch to the development web server (Cassini) for debugging, so that I can use features like edit and continue. The reason that I'm not, is because the development web server only starts up when you are in debug mod...

Delphi: Why does "use debug DCUs" become ineffective if I'm using packages in my project?

I'm building a project that uses the JVCL plugin system, which relies on Delphi packages, and ever since I added it to my project, debugging has become a nightmare because I'm no longer able to step-trace into the source of any VCL or RTL units. They're all marked as gray dots in the debugger, (when the relevant functions appear at all ...

Script Debugging Not Working (VS 2008)

I recently installed VS 6.0 after installing VS 2008 and overwrite JIT settings .. when i started VS 2008 option dialog .. it said another debugger has taken over VS 2008 debugger and I asked me to reset .. so I did .. Now everything works fine except javascript debugging. I am unable to debug javascript .. I can set breakpoint .. but i...

Fix browser bugs as you go or save them up till the end?

With CSS bugs, do you fix them as and when they arise during each stage of your development, or do you save them up till the end? as I'm at quite an early stage in a large project and seem to be getting bogged down with annoying IE6 bugs. ...

Reflecting local variables

I'm trying to find a way to automate some exception logging code to add to the stack information already available. Is there any way to use reflection to retrieve the values of all variables on the stack (locals and parameters) - I sincerely doubt the names of the variables are available, but in many cases it would be useful to see the ...

How can I check whether I am in a debug or release build in a web app?

In any (non-web) .net project, the compiler automatically declares the DEBUG and TRACE constants, so I can use conditional compiling to, for example, handle exceptions differently in debug vs release mode. For example: #if DEBUG /* re-throw the exception... */ #else /* write something in the event log... */ #endif How do I ob...

Unhandled exceptions in BackgroundWorker

My WinForms app uses a number of BackgroundWorker objects to retrieve information from a database. I'm using BackgroundWorker because it allows the UI to remain unblocked during long-running database queries and it simplifies the threading model for me. I'm getting occasional DatabaseExceptions in some of these background threads, and I...

DebuggerDisplay on generic class

I have a problem applying the DebuggerDisplay attribute on a generic class: [DebuggerDisplay("--foo--")] class Foo { } [DebuggerDisplay("Bar: {t}")] class Bar<T> { public T t; } When inspecting an object of type Bar<Foo> I would expect it to show as Bar: --foo--, but I get Bar: {Foo} What am I doing wrong? ...

How can I avoid automatically attaching to T-SQL for debugging in Visual Studio 2008?

When debugging web sites that I'm working on, I tend to use Attach to Process rather than F5 to start debugging (since the site's already on in Firefox). However, occasionally when doing so, I'll get the following error: EXECUTE permission denied on object 'sp_sdidebug', database 'master', owner 'dbo'. I know this is caused by att...

Why do I get "Unable to start debugging on web server" when running asp.net?

I am trying to debug a web application through IIS that has a virtual directory other than localhost. It compiles fine but gets the above message anytime that I try to start debugging. I have compilation debug="true". ...

Bug distribution

I have a program that I'm porting from one language to another. I'm doing this with a translation program that I'm developing myself. The relevant result of this is that I expect that there are a number of bugs in my system that I am going to need to find and fix. Each bug is likely to manifest in many places and fixing it will fix the b...