Home > Articles > Programming > Windows Programming

  • Print
  • + Share This
This chapter is from the book

This chapter is from the book

Remote Debugging

Every time we have a discussion with someone regarding debugging ASP pages, we always ask if that person has ever tried to set up ASP debugging on the local machine. The response usually is "yes." We then follow up with the question of if that person has ever gotten it to work. The number who answer "yes" to that question is much lower. Finally, we ask if that person has ever gotten ASP debugging to work remotely. We have yet to find someone who has gotten it to work properly and consistently.

With ASP.NET and Visual Studio .NET, that all changes. It finally works. And it couldn't possibly be easier to install, configure, and use.


When you install Visual Studio .NET on your server, all you need to do is install both Remote Debugging options listed under the Server Components option during the install procedure.


To configure remote debugging, the only thing you need to do is place your user account into the newly created Debugger Users group both on the client machine and on the server machine. This can be done using the standard user configuration tools that are part of whichever Windows operating system you are using.

Using It

This is the easiest part of all. To use the new remote debugging features, simply create a project on your client computer that points to the project running on the server. This can be done by choosing Open Project from the Web from the File menu. Just type in the name of the server where the project resides, and you will be presented with a list of projects currently residing on that server. Choose the appropriate one.

If you are not connecting to an existing project, you can create a brand new project on the server, and remote debugging will still take place.

Next, set a breakpoint on the line where you want to stop, or simply start the application running. It will connect to the server and bring up an Internet Explorer window, as usual. The big difference here is that the application is running entirely on the server. When you hit your breakpoint, you are hitting it on the server, in the server's memory space. The same goes for components and anything else that you might be debugging. Everything that can be debugged in Visual Studio .NET locally can now be debugged remotely on any server where the remote debugging options have been installed.

And that's it! It's almost completely automatic. I wish it was this easy in Visual Studio 6.0—it's a huge time saver and a powerful tool.

  • + Share This
  • 🔖 Save To Your Account