Step-by-step debugging web form code-behind in Visual Studio

#1

Use the following method for step-by-step debugging of web form code-behind using breakpoints in Microsoft Visual Studio.

Note: You must use Visual Studio (Pro or Community, versions 2013 or 2015) installed on a local computer hosting a WorkflowGen test environment. While it might be possible to debug your web forms remotely, this method is not covered in this FAQ; refer to your Visual Studio documentation for more information.

  1. Start a new instance of Visual Studio.

  2. Select File > Open > Web Site.

  3. In the window that opens, select Local IIS from the left-hand pane, then browse to the WorkflowGen website’s WebForms folder (\WorkflowGen\wfgen\wfApps\WebForms) and open it.

  4. Open the \WebForms\web.config file (or create a new one if it does not exist), then set the compilation element’s debug attribute to true.

    Example

    <?xml version="1.0"?>
    <configuration>
        <system.web>
        <compilation debug="true"/>
        </system.web>
    </configuration>
    
  5. Set the breakpoint at the line of code in the default.aspx page of the web form you’re debugging.

  6. Select Menu > Debug > Attach to process and check Show processes from all users.

  7. Select the WorkflowGen application process from the list and attach it. (The process should be listed as w3wp.exe with the User Name IIS APPPOOL\[your WorkflowGen Application Pool name].)

  8. Return to the web browser and launch a new request. When the breakpoint is hit, the Visual Studio window will come to the foreground and allow you to debug.

#2

Hi,

Unfortunately I cannot reproduce this steps in order to debug while I’m attached to the process.
I receive a message:

The breakpoint will not currently be hit. No symbols have been loaded for this document.
Is it possible that you could send all of the necessary .pdb files?

Thanks,
Hubert