Поделиться через


Debugging in Visual Studio

You have created your application and resolved the build errors. You must now correct those logic errors that keep your application or stored procedures from running correctly. You can do this with the development environment's integrated debugging functions. These allow you to stop at procedure locations, inspect memory and register values, change variables, observe message traffic, and get a close look at what your code does.

Note

Windows Store apps

The Visual Studio debugger provides complete support for debugging Windows Store apps that run on Windows 8. For more information, see the following sections in the Windows Dev Center:

In This Section

  • What’s New for the Debugger in Visual Studio 2013
    Describes new functionality in Visual Studio 2013

  • Debug your app by recording code execution with IntelliTrace
    Find bugs faster and easier by recording your app's execution history with IntelliTrace. Browse recorded events and function calls to review related code, artifacts, and data from the Locals window at key points in time. This lets you debug your app without having to set lots of breakpoints or restart your app as often. Requires Visual Studio Ultimate.

  • Debugger Security
    Discusses security issues related to debugging.

  • Debug Settings and Preparation
    Covers the Project Property settings and setup you must perform to create a debug build for your project. Also covers setup for remote debugging, debugging Code Center Premium source, debugging a partial-trust application, and debugging a high-performance cluster application.

  • Debugger Roadmap
    Discusses the fundamentals of using the Visual Studio debugger. Topics include debugging basics, execution control, attaching to a running program, Just-In-Time debugging, launching the debugger automatically, dumps, breakpoints, inspecting your program, handling exceptions, Edit and Continue, and using expressions in the debugger.

  • Links to debugging Windows Store apps
    Provides link to information about running and debugging Windows Store apps on Windows 8.

  • Debugging Managed Code
    Covers common debugging problems and techniques for managed code written in Visual Basic, Visual C#, and C++.

  • Debugging Native Code
    Discusses some common debugging problems and techniques for C and C++ applications.

  • Debugging GPU Code
    Describes how to debug C++ code that is running on the graphics processing unit (GPU).

  • Debugging Web Applications and Script
    Describes common debugging problems and techniques you might encounter when debugging Web applications. Sections include debugging ASP.NET and ASP Web applications, debugging ATL Server Web applications, Web server debugging errors, and troubleshooting.

  • Debugging WCF Services
    Describes debugging techniques and limitations for WCF services that run in Internet Information Services (IIS), on an ASP.NET development server, or that run as a self-hosted service.

  • Debugging DirectX Graphics
    Describes diagnostic tools that you can use to help solve rendering problems in DirectX-based games and apps.

  • Debugging User Interface Reference
    Provides reference information on the windows and dialog boxes you use when debugging your application. These topics are also available when you press F1 while you have focus on a debugging user interface element, such as the Breakpoints window.

  • Debug Interface Access SDK
    Describes the Microsoft Debug Interface Access Software Development Kit (DIA SDK). The DIA SDK provides access to debug information stored in program database (.pdb) files generated by Microsoft postcompiler tools.

  • Walkthrough: Debugging an Add-In Project
    Add-ins are compiled applications that use the Visual Studio automation object model to manipulate or automate the integrated development environment. This topic shows how to debug a Visual Studio add-in project

  • Deploying Applications, Services, and Components
    Provides links to various deployment topics including: deployment concepts, introduction to Microsoft Windows Installer, deployment projects, merge module projects, creating or adding deployment projects, setting properties, adding items to a deployment project, and opening the deployment editors. This section also covers managing file installation, registry settings, file types, user interface, custom actions, and launch conditions.