Debug the ACCT Application

You can start debugging your CICS application by using the Enterprise Server Dynamic Debugging facility, which enables you to debug a service on a local or remote enterprise server.

Set Enterprise Server Debug Options

You can set debug options that turn on some Enterprise Server behaviors automatically such as starting the enterprise server region and dynamic debugging. Before setting these options, you must first stop the :enterprise server region.

  1. To stop the ESACCT enterprise server region, in Server Explorer, right-click ESACCT on the list of servers, and then click Stop.
  2. From the Visual Studio menu, click Tools > Options, expand Micro Focus, and then click Enterprise Server.
  3. Check the following options:
    • Automatically start the associated server
    • Automatically enable dynamic debugging
  4. Click OK.

Set Project Properties for Debugging

  1. Select your project in Solution Explorer and click Project > Properties
  2. Click the Debug tab.
  3. Ensure Choose Active Settings is set to CICS.
  4. Type ACCT in the Transaction text box.
  5. Click File > Save All.

Debug the ACCT Application

  1. Click Debug > Start Debugging.

    This starts the ESACCT enterprise server region automatically, and loads CICS into the Mainframe TN3270 Display.

    Note: If the embedded Rumba TN3270 Mainframe display is not displayed when debugging starts, click GUID-5BAA56BC-A0AF-4173-8CE7-D6C0CB602FFC-low.png on the debug toolbar to open it.
  2. In Rumba press CTRL+SHIFT+Z to clear the screen.
  3. Enter ACCT to run the application.

    In Visual Studio, the debugger stops the execution of the process and positions the cursor in the Procedure Division of the ACCT00.cbl file.

  4. Step through the application in the usual manner.

Stop Debugging

To stop debugging:

  1. To stop debugging, click Debug > Stop Debugging.
  2. To stop the server, right-click ESACCT in Server Explorer, and click Stop.
Note: It is important for you to stop the debugger before you stop the enterprise server. This stops all the active transactions and ensures the enterprise server stops cleanly.