Debugging the Accelerator Core Code

  • 724 Views
  • Last Post 18 March 2016
DerekMaciak posted this 08 March 2016

When you install the Accelerator, the core dlls are included in release and debug versions as well as all the source code is included.

The release DLLs are what your projects reference from default generation.

Here are the folder paths based on installing at C:\Program Files\Accelerator for .NET\v6_2\.

  • Core Release DLLS
    • C:\Program Files\Accelerator for .NET\v6_2\Core\DotNet
  • Core Debug DLLS
    • C:\Program Files\Accelerator for .NET\v6_2\Core\DotNetDebug
  • Source Code files
    • C:\Program Files\Accelerator for .NET\v6_2\Source

If you want to debug the Accelerator Code from your system, all you need to do is point your <A4DNCoreHintPath> element that is located in your A4DNReference.msbuild file to the Core\DotNetDebug folder.

You will need to restart your Visual Studio environment for the change to take effect.  You can then open the source files located in your source folder and have fun debugging.

Note: It is also recommended to run your build script. This will ensure the Accelerator DLLs with debug symbols are properly loaded into your bin folder.

Remember to set the  Core\DotNetDebug folder back to Core\DotNet when you are finished.

<?xml version="1.0" encoding="utf-8"?>
<Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
  <PropertyGroup>
    <A4DNVersion>6.2.0.0</A4DNVersion>
    <A4DNCoreHintPath>C:\Program Files\Accelerator for .NET\v6_2\Core\DotNetDebug\</A4DNCoreHintPath>
    <A4DNSilverlightHintPath>C:\Program Files\Accelerator for .NET\v6_2\Core\Silverlight\</A4DNSilverlightHintPath>
    <A4DNMaintenanceHintPath>C:\Program Files\Accelerator for .NET\v6_2\Maintenance\</A4DNMaintenanceHintPath>
    <A4DNCodeFactoryHintPath>C:\Program Files\Accelerator for .NET\v6_2\CodeFactory\Wizards\</A4DNCodeFactoryHintPath>
    <A4DNJobMonitorHintPath>C:\Program Files\Accelerator for .NET\v6_2\JobMonitor\</A4DNJobMonitorHintPath>
  </PropertyGroup>
</Project>

Order By: Standard | Newest | Votes
DerekMaciak posted this 18 March 2016

Here is an example of debugging AB_DetailBase which is what my CustomerDetail inherits from.

I can open the souce to this file in Visual Studio by clicking the menu item File --> Open --> File.

Since I am using Accelerator version 6.2, I opend the source file from:

C:\Program Files\Accelerator for .NET\v6_2\Source\AB_DetailBase.cs

I can then add break points in the code and debug.  

DerekMaciak posted this 18 March 2016

Here is an example of debugging the service Layer.  If you want to debug Accelerator code that runs in your service layer, you need to make sure you are running your services locally (Check your Services.config and ConnectionParms.config).

You can debug any of the SQL statements using the appropriate interpreter:

AB_InterpreterForDB2 - Use this when accessing tables in DB2 on the IBMi

AB_InterpreterForMSSQL - Use this when accessing tables in Microsoft's SQL Server

AB_InterpreterForzOSDB2 - Use this when accessing tables in DB2 on the IBM z/OS

Here is an example of debugging the am_ExecuteSelect in the AB_InterpreterForDB2.

Open the iCMD CommandText to see the SQL Query.

Close