Getting started

First you need to download and install Prism for AL. Head over to the download page to download the installer. Running the installer is straight-forward.

Press the Get trial license link in the Control panel:

Unlicensed Prism for AL Control Panel

The Trial license window now pops up:

Prism for AL: Request trial license window

Enter your details and press the Submit button. We will immediately email your trial license to the email address you have entered.

Open your email client, fetch new mails and open the email from us. You can now go ahead and install the trial license.

Copy the license key we emailed to you to the clipboard. Make sure to copy the whole key.

In Prism for AL's Control Panel, press the Enter license which opens the License key window:

Prism for AL license key

Paste in the license key and click Activate. You are now ready to open your first workspace.

Prism for AL features a number of ways to open a solution. You probably already have a Visual Studio Code AL project available, so to get started, here is what you do:

First, make sure you have used AL: Download symbols in Visual Studio Code. This is because Prism for AL needs access to the dependencies.

Then, if you have a .code-workspace file, click the button Open workspace in the Control panel and select the .code-workspace file.

Else, if you have Visual Studio Code AL project folder, click the button Open folder in the Control panel and select the folder.

Prism for AL will now load all objects including those defined in dependent packages. The first load of new package is always slower due to Prism filling its cache. You can speed up first time loads by excluding Prism for AL's cache folder from virus scanning, see Package cache.

You are now ready to browse code and analyze your code including Base Application and other dependencies. Check out the next section for your possible next steps.

Depending on your learning preferences, do any of the following or mix them to familiarize yourself with Prism for AL:

If you get stuck or have any questions, simply email us at feedback@stati-cal.com.

Videos New

Using Prism for AL

Whenever you see a hand cursor, you can left-click and/or there is a context menu available. Right-click will activate the context-menu.

Many UI elements have tooltips, both in the code views and elsewhere in the UI. Hover the cursor over the element and the tooltip will show after a small delay.

The workspace window dividers can be dragged for resizing and double-clicked to collapse/expand the object index and object outline section of the workspace:

Prism for AL: Adjust window dividers

The object outline can be opened in a separate window using the "File | Outline" menu.

To help you narrow objects shown in the object index, results in find usages windows etc, Prism for AL allows you to enter filter expressions.

All matching of search expressions against strings is case-insensitive. The following kinds of filter syntax is used:

  • You can search both entity name and number
  • For names, you can use * and ? as a wild-cards
  • For names, use space to separate words; we implicitly add wildcards around each word
  • For numbers, you can use .. for ranges
  • You can use | as an or operator
Example: When matched against objects, 18..20|..4|cust entr is matched by Codeunit 19 (because 19 is between 18 and 20), XmlPort 1 (because 1 less than 4) and Page "Customer Ledger Entries" (because name includes 'cust' and 'entr' in that order).

The control panel and the workspace window have sevaral shortcuts available for their menu items. These are printed following the menu item name.

Additional shortcuts are available for recent items in the control panel:

Shortcut Description
Ctrl + 1 Open recent workspace (1st from the top)
Ctrl + 2 Open recent workspace (2nd from the top)
Ctrl + <n> Open recent workspace (nth from the top)

The following shortcuts are available for closing windows:

Window Shortcut Description
Workspace Alt + F4 Closes the focussed workspace window. Depending on the setting Confirm closing workspace you will be prompted to confirm.
Control panel Alt + F4 Closes the control panel window including all workspace windows. If any workspaces are open, depending on the setting Confirm closing workspace you will be prompted to confirm.
Any other window ESC If the setting Escape closes window is checked, then Escape closes the currently focussed window/dialog/pop-up.

In many places such as the Usages window you can copy the result to clipboard using the copy to clipboard icon:

Prism for AL: Copy to clipboard
Copy to clipboard.

Tabular results are TAB separated, so you can paste directly into e.g. Excel.

Use expanders to collapse/expand individual items:

Prism for AL: Expanders for individual items and expand/collapse all
Expanders.
# Description
1 Expands or collapses individual items
2 Expands or collapses all items

Reference manual

Term Description
App

An app is an add-on (extension) to Business Central in as defined by Microsoft. We also regard Base Application, SystemApplication, Application and System as well as localizations etc as apps.

Synonyms: Module.

Code graph

Prism for AL is capable of exporting syntax, references and flow information into a graph database. We call this the code graph of a workspace. This enables a set of features such as Flows to and Flows from.

Compilation unit A compilation unit is a unit of compilation, i.e. something we feed into our parsers. Compilation units can be either .al files or an object within SymbolReference.json inside an .app file. Error handling in case of parse errors is at compilation unit level.
Flow In Prism for AL, flow refers to reachability control flow, i.e. paths of code that might be traversed through execution of AL code. Here are some characteristics of our implementation:
Topic Description
Statements and expressions Statements have flow to subsequent statements (separated by ;), sub-statements (e.g. the if-branch of an if statement), and expressions (e.g. the if condition). Procedure calls have flows to the called procedure.
Event publishers and subscribers A call to an event publisher has flows to all subscribers.
Interface calls A call to an interface method has flows to all methods that implement the method.
Running objects A call like Codeunit.Run(Codeunit::MyCodeunit) has a flow to the codeunit's OnRun trigger. Similarly for other object types. Currently, a call like Codeunit.Run(myVariable), where myVariable is a variable, has no flow to the OnRun trigger.
Triggers The code graph models flows to triggers. For example, myRec.Validate(MyField, 42) has a flow to the OnValidate trigger of MyField.
Properties Properties that have AL expressions as values have flows to the nodes representing the expression.
User actions User actions such as pressing an action button are modelled as special nodes in the code graph and may initiate flows.
Module See App.
Module dependencies Modules can depend on other modules in a number of ways:
Module dependency graph Modules and their dependencies constitute a directed graph with modules as nodes and dependencies as edges.
Module metadata Data about a module found in Visual Studio Code app.json files and NavxManifest.xml files in packages.
Package A .app file, which is the output of the AL compiler and can be published to a Business Central server.
Symbol file The SymbolReference.json file found within packages. Prism for AL uses these files when source code is not available.
Topological order The topological order induced by the module dependency graph. When modules are sorted in topological order, dependencies are always pointing backwards thus giving a natural order in which to understand modules. The topologic order is used in e.g. the Object index for sorting and for applying changes from multiple extensions in the correct order for the Extended view.
Workspace

Workspace is quite an overloaded word which basically means space in which you work, so the meaning depends on your context, i.e. what you work with.

In Visual Studio Code, workspace is a folder with an app.json and .al source files or a .code-workspace file pointing to multiple such folders.

In Prism for AL, workspace is generalised to include any collection of modules you choose to view and analyse together as a solution (code-base) and does not distinguish much whether a module is a Visual Studio workspace or a package which your solution depends on.

Control windows

Prism for AL control panel
The control panel.
# Name Description
1 Open workspace

Opens a workspace based on Visual Studio Code .code-workspace file.

Once the file has been selected, the Loading window opens.

2 Open folder

The simplest usage of Open folder is to open a Visual Studio Code project folder, i.e. a file system folder containing an app.json file and (usually) also .al files.

Prism for AL can also open a folder that has sub folders (recursively) that are Visual Studio Code projects such as this:

├───app-A
│   │   app.json
│   │   DoThis.Codeunit.al
│   │
│   └───.alpackages
└───app-B
│   app.json
│   DoThat.Codeunit.al
│
└───.alpackages
This works similar to opening a workspace file.

Another option is to open a folder which contains packages (.app files) and no app.json files at all (recursively). This will create an in-memory artificial module with dependencies for all distinct packages in the workspace. This can be used to browse on-prem installation media (select the Applications folder).

Once the file has been selected, the Loading window opens.

3 Open package

Opens a package file (*.app).

This will create an in-memory artificial module with a dependency to the single package. Package dependencies are not included; to achieve that, use Open folder instead.

Once the file has been selected, the Loading window opens.

4 Memory cache

When this settings is enabled (default), then Prism for AL will snapshot the source files found in workspace folders (but not source code found in .app files) during loading.

This insulates the viewing experience from file changes by an external editor like Visual Studio Code. However, it also increases memory usage. You can monitor usage in the workspace window.

Notice that this setting affects opening of new workspaces as well as opening of recent items. The setting does not survive restart of Prism.

5 Package resolution options

The following settings control how packages are resolved during loading:

  • Search Depth: This setting determines determines how deep package resolution will go into dependencies. See search depth values table below for available options. Set the default value in the Settings window.
  • Search Package Cache: If enabled, and a module cannot be found in a package file in the workspace then Prism will look in the package cache directory as well. Caution: this may produce unexpected results as the package version may be much older or newer than the expected workspace package.

Notice that these settings affect opening of new workspaces as well as opening of recent items. The settings do not survive restart of Prism.

6 Recent This is a lists of workspaces you have opened recently sorted in reverse chronological order. Click a recent workspace or use shortcuts Ctrl + 1, Ctrl + 2 etc (counting from the top) to open open the workspace. If the workspace is already open, focus shifts to the workspace window. Recent items offer a context menu, see below.
7 License

The license part shows the current license (if any is installed) and it's status. The tooltip on the status gives additional information, e.g. expiration date when the license is valid.

Without a license, Prism for AL is feature-limited. Subscribe or get a trial license to enable all features.

Click the Enter license button to open the License window.

8 Settings Opens the Settings window.
9 Package cache Opens the Package cache window.
10 Feedback Opens the Feedback window.
11 Release notes Opens your default browser with on the release notes page for Prism for AL.
12 Status Watch this for status messages like availability of new releases of Prism for AL. Click the status to open your default browser on the download page for Prism for AL.

Search depth values (dotted lines in the pictographs are propagated dependencies):

Mnemonic Description Pictograph
W Workspace:
Workspace modules (app.json), only. No packages are included.
Prism for AL: Resolve workspace only
W→P Workspace and direct dependencies:
Workspace modules (app.json) as well as direct package dependencies (*.app)
Prism for AL: Resolve workspace and direct dependencies
W→PP Workspace and direct/propagated dependencies:
Workspace modules (app.json) as well as direct package dependencies (*.app) and their propagated dependencies.
Prism for AL: Resolve workspace, direct dependencies and propagated dependencies
W→P→* Workspace and transitive dependencies:
Workspace modules (app.json) and all dependencies transitively (recursively)." Notice that this setting may lead to unexpected results as old, now unused packages in Visual Studio Code .alpackages folders may be included.
Prism for AL: Resolve all dependencies transitively

File menu:

Menu item Description
Open Opens a workspace. The submenus correspond to the open buttons.
Recent The submenu contains a list of recently opened workspaces (like the recent section). Click to open.
Package Cache Opens the Package cache window.
Settings Opens the Settings window.
Close Open Workspaces Closes all open workspaces. If the setting Confirm closing workspace is checked, then a confirmation dialog pops up.
Exit Exits Prism for AL.

Help menu:

Menu item Description
Learn Opens your default browser on the learning page you are currently reading.
Optimize Prism Package Cache Performance Copies to clipboard a PowerShell script to exclude Prism's cache directory for Windows Defender. See also Package cache.
Feedback Open the Feedback window.
Terms and Conditions Opens Statical Prism Terms & Conditions document (PDF)
Third-Party Licenses Opens windows with third-party licenses information of components used by Prism for AL.
OpenJDK
  • Licenses: OpenJDK licensing information
  • Source Distribution Offer: Our offer to distribute OpenJDK source code.
Log Prism logs diagnostic messages to rotating log files as well as to in-memory session log for the current session (run of Prism). Notice that the log level setting does not survive restart of Prism. The submenus are:
  • Open log: Opens the current log file in your default text editor
  • Open session log: Opens the session log in your default text editor
  • Wipe log file: Empties the current log file; previous log files are left unchanged
  • Log level Information: Click to select normal log level
  • Log level Debug: Click to select debug log level; we may ask you to do this when diagnosing an issue
  • Log level Verbose: Click to select verbose log level; we may ask you to do this when diagnosing an issue
Version Check Runs an up-to-date check to see if the installed version of Prism for AL is the newest version available. If not, you should update to the latest version.
Enter License Open the License dialog.
Get Trial License Open the Trial license window.
About Displays information about Prism for AL. Please make sure to download a newer version of Prism for AL before the executable expires date.

Recent context menu:

Menu item Description
Open Workspace Loads the workspace if not already opened with the current package resolution options (not those at the time of the last opening of this workspace).
Reveal in File Explorer Opens Windows File Explorer highlighting the folder or file corresponding to the workspace.
Remove Recent Item Removes the workspace from the recent list.
Remove All Recent Items Empties the recent list.

The Loading window is opened when opening a workspace. The main activities are:

  • Locate workspace app.json file(s)
  • Locate available package files (typically in .alpackages, but depends on setup in Visual Studio Code)
  • Parse app.json
  • Parse NavxManifest.xml files from packages
  • Resolve dependencies from app.json and NavxManifest.xml taking into account the dependency declaration's version. Package resolution is influenced by package resolution options.
  • Parse .al files from workspace folders and packages where source code is available
  • Parse SymbolReference.xml for packages where source code is not available
  • Index object members and object level dependencies

Prism for AL loading a workspace
Loading a workspace.
# Name Description
1 Current activities The current load activity or activities.
2 Overall progress The overall progress bar is indefinite until all packages have been cached.
3 Workspace Folder, .code-workspace or .app file being loaded.
4 Timer Time spent loading.
5 Cancel Click to cancel the loading process.

Prism for AL settings
Settings.
# Name Description
1 Full path to code.cmd Full path to Visual Studio Code's code.cmd file. Normally, you can leave this blank as the containing folder is in Window's PATH environment variable.
2 Default search depth This is the default value of .
3 Remember code line selections Check to make Prism for AL remember selected code lines of an object when navigating to other objects. Notice that when you restart Prism for AL or reload a workspace, code lines selections are lost.
4 Expanded filter panel Check to always expand the filter panel of the Usages window.
5 Show filter button presence effect Check to show effect on filter button when a filter is available in the Usages window.
6 Expanded result groups Check to expand usages groups when the Usages window is opened.
7 Show filter ratio bar Check to show bar at bottom of Usages window that indicates the ratio of the search results that are currently displayed.
8 Window width Adjust the initial width of the Usages window when opened.
9 Window height Adjust the initial height of the Usages window when opened.
10 Result limit The maximum number of flow nodes fetched for display in the Flows window. This is a safeguard mechanism, and the default value of 2,000,000 should be sufficient for normal size workspaces.
11, 12, 13 Manual refresh of result set When enabled and the conditions apply, then auto-refresh is disables in the Flows window.
14 Minimum heap size Minimum heap size of the graph server process.
15 Maximum heap size Maximum heap size of the graph server process. If a graph server process reports out of memory exceptions, then consider to increase this value.
16 Hardware-accelerated graphics If checked (default), UI rendering allows hardware acceleration. Uncheck to disallow hardware acceleration. Unchecking this may solve rare conditions caused by erroneous graphics drivers.
17 UI virtualization in usages windows For large result sets, expanders sometimes forget their open/close state. Chech this settting to prevent this from happening.
18 Show startup animation Check to show animation when Prism for AL starts.
19 Confirm closing workspace If checked, asks before closing a workspace
20 Escape closes window If checked, ESC closes windows apart from control panel and workspace window.
21 Selected item cursor blink count Sets the number of times Prism for AL's declaration cursor blinks next to the selected code line when navigating.
22 Selected item cursor scale factor Sets the scale factor for Prism for AL's declaration cursor next to the code line navigated to. The default value is 1.00, so 2.00 doubles the size.
23 Show toolbar button labels Determines whether toolbar buttons contain descriptive texts. A few toolbar buttons do deliberately never have button labels.
24 Save Saves changes. Saved settings are persistent, so will survive restart of Prism for AL.
25 Undo Resets values back to just after last Save.

File menu:

Menu item Description
Save Saves changes. Saved settings are persistent, so will survive restart of Prism for AL.
Undo Resets values back to just after last Save.

The primary purpose of the package cache is to optimize load performance. A secondary purpose is to allow package resolution to include packages not found in the workspace, see Search depth. Basically, the cache consists of artifacts extracted from .app files. The location of the cache is %LOCALAPPDATA%\Statical\PrismAL\PackageCache.

Prism for AL writes to the cache during loading when encountering a new package or a new version of a known package. Anti-virus programs can slow down this process significantly, so – if your security policy allows – you may consider excluding the cache folder from being scanned. If you are using Windows Defender, you can use PowerShell to exclude Prism for AL's cache directory. See below how to obtain a PowerShell script for Windows Defender. For other anti-virus programs, please check the documentation.

Prism for AL package cache
Package cache.
# Name Description
1 Copy script to clipboard Copy PowerShell script for excluding Prism for AL's package cache from Windows Defender to clipboard.
2 Publisher The module's publisher. Click to sort.
3 Name The module name. Click to sort.
4 Version The module's version. Click to sort.
5 Size The size on disk of this cache entry. Click to sort.
6 Wipe selected package Select a package by clicking a row. Then click Wipe selected package to remove the package from the cache.
7 Wipe all packages Click to empty the cache. This will save disk space, but will slow down first-time loading of workspaces.
8 Ok Closes the window.

When no license is installed, the control panel's license part has a link that opens the trial license page. Submit your details to receive a trial license by email. If you have recently received a trial license from us, we may reject the request. Of course, you can always contact us a ask politely for another trial if you are not yet convinced of subscribing.

Prism for AL trial license
Trial license.
# Name Description
1 Name Enter your name.
2 E-mail Enter your email address. Use your company email address.
3 Company name Enter the name of the company you work for.
4 Phone Enter your phone number, if you want ús to be able to call you.
5 Tell us Tells us how you heard about Prism for AL. This helps us understand how to reach potential customers.
6 We respect your privacy Opens your default browser with our privacy policy.
7 Submit Click to submit.
8 Cancel Click to cancel the request and close the window.

The license key window is accessed from the control panel. When you have received a license key for your subscription or a trial license key, enter it in the License key window:

Prism for AL license key
License key.
# Name Description
1 License key Paste in the license key here. Be careful to copy the whole key, as license keys may include characters which some editors regard as separators when selecting text.
2 Activate Click to activate key. If the key is not valid, please ensure that you have pasted in the whole key. Also check the tooltip of the license status. in the control panel.
3 Cancel Leaves the current license key in place, if there is one, and closes the window.

The Feedback window is available from menus in both the Control panel and the Workspace window.

Use the window to give us feedback such as:

  • Ideas for new features
  • Ideas for changes to current features
  • Bug report
  • Your favourite feature
  • Example of hard problem you solved with Prism

Prism for AL feedback
Feedback.
# Name Description
1 Feedback Enter a description of the idea, bug etc.
2 Email address Enter your email address. This is optional, but without the email address we do not know who you are, so we cannot get back to you with clarifying questions or simply a status.
3 Attachment Use the file selector to select a single file you want to attach.
4 Attach log file Check this to attache the tail of the current log file. THis helps us diagnose the problem.
5 Attach clipboard image Check this is you have taken a screenshot and copied it to clipboard or intent to do so before submitting the feedback.
6 Send/Cancel buttons Click Send to send the feedback to us optionally including a file attachment, the tail of the log file, and an image from the clipboard. Click Cancel to close the feedback window.

Workspace windows

The workspace window is Prism's main window once a workspace has been opened:

Prism for AL workspace window
The workspace window.
# Name Description
1 Current object The object that is currently selected. Right-click to open the object context-menu.
2 View selector Select how you want to see objects
  • Object: Prism presentation of object
  • Extended: Object including extensions
  • Source: Plain source code
  • Dependencies: In- and outbound dependencies of current object
3 Object index (part) Index of the all objects in the workspace including dependencies, see Object index.
4 Object details (part) This part shows details of the current object depending on View selector. The default view is Extended view.
5 Object outline (part) This part outlines the contents of the current object, see Object outline. The outline is hidden when current view selection is .
6 Back and forth navigation arrows Use the back for forth navigation arrows to navigate your browsing history. You can also navigate history with the following shortcuts:
  • Back: ALT + LEFT or MOUSE BACK
  • Forward: ALT + RIGHT or MOUSE FORWARD
7 Reload button Reloads the current workspace. Use this button when workspace files (typically .al or app.json) are changed on disk, for example when you have edited the files in Visual Studio Code. See also Memory cache
8 Build graph button Builds a code graph for the currently open workspace.
9 Compilation unit parse errors This button is enabled and red if any parse errors where encountered during workspace loading. Click to view compilation unit errors
10 Graph build errors This button is enabled and red if errors occurred when generating a code graph for the current workspace. Click to view graph generation errors
11 Control panel button Focuses the Control panel window.
12 Settings button Opens the Settings window.
13 Solution Opens the Solution window.
14 Module graph Opens the Module graph.
15 Outline button Opens the Object outline in a separate window, which sticks to the object that was current/selected when opened.
16 Object namespace display This dropdown determines if and how namespaces are displayed for object references:
  • Source: Show namespace qualifiers as they are written in the source code (default).
  • Qualified: Always show namespace of object references.
  • Unqualified: Never show namespace of object references.
17 Current package Displays the name of the current object's module. Click to open reveal in the Module graph. If the module has symbols only (source code not available), then the module name us postfixed with an asterisk (*).
18 Workspace path Left-click the path to open or reveal .code-workspace file in Window File Explorer, depending on how the workspace was opened.
19 Resolution depth Shows the resolution depth this solution was opened with.
20 Source cache memory consumption Shows the amount of memory consumed by caching of source files in the workspace folder(s). This is only displayed when the workspace folder(s) contains .al files and memory cache was enabled when opening the current workspace.
21 Language selector Select the language in which you want to see label translations. You can set a default value in the Settings window.

File menu:

Menu item Description
Control Panel Shows and focuses the control panel.
Explore Opens the workspace file explorer window for the current workspace.
Close Closes the workspace and updates the control panel's Recent items, so it is easy to open the same workspace later. You can also close a workspace by closing the window.

View menu:

Menu item Description
Go to Position Opens a dialogue where you can enter a character position relative to the current object's start position within the .al file. Click "OK" to navigate to the position in Source view.
Extended Object Swiches to Extended view of the current object.
Object Swiches to Object view of the current object.
Source Swiches to Source view of the current object.
Dependencies Swiches to Dependency view of the current object.
Open Dependencies in New Window Opens the Dependency view of the current object in a separate window.
Module Graph Opens the Module graph.
Outline Opens the Object outline in a separate window which sticks to the object that was current/selected when opened.

Search menu:

Menu item Description
Fields Opens the Search fields window.
Procedures Opens the Search procedures window.
Event Publishers Opens the Search event publishers window.
Free Text Search (Current Object) Opens the Free text search window pre-configured for the current object.
Free Text Search (All Objects) Opens the Free text search window pre-configured for searching all objects.

History menu:

The history menu lists all objects and places within objects which you have navigated to or from since the workspace was opened. The history is in reverse chronological order and marks the last visited entry with green colour.

Click any history item to re-navigate. Re-navigation does not affect the history other than green marking. You can also navigate history with the back and forth arrows.

Reports menu:

Menu item Description
Save Object Dependencies Object dependencies are useful to monitor in order to manage dependencies. This function produces a cross-reference of object references within the workspace as a .csv (tab separated) file.
  1. Select your output file
  2. Click the "Save" button
  3. Open in e.g. Excel and use "Text to Column"
The file lists source location, target location and dependency type (e.g. Variable or TableRelation) and for some types also a sub-type (e.g. sub-type SourceTable of type Property.)
Save Unreferenced Objects Unreferenced object are potentially 'dead' code that should be cleaned up. This function produces a list of objects that are not referenced by any other objects. Such objects may still be used, though, e.g. object extensions (which cannot be referenced at all at object level) and event subscribers which are also not referenced (instead, references are the other way (from the subscriber to the publisher.) To use:
  1. Select your output file
  2. Click the "Save" button
  3. Open in e.g. Excel and use "Text to Column"
Save OnPrem Procedure Usages It is good practice to keep the number of dependencies to OnPrem annotated code as low as possible. To enable this report, please make sure to build a code graph. This function produces a list of usages of OnPrem functions and objects. To use:
  1. Select your output file
  2. Click the "Save" button
  3. Open in e.g. Excel and use "Text to Column"

Help menu:

Menu item Description
Learn Opens your default browser on the learning page you are currently reading.
Feedback Open the Feedback window.
Log Prism logs diagnostic messages to rotating log files as well as to in-memory session log for the current session (run of Prism). Notice that the log level setting does not survive restart of Prism. The submenus are:
  • Open log: Opens the current log file in your default text editor
  • Open session log: Opens the session log in your default text editor
  • Wipe log file: Empties the current log file; previous log files are left unchanged
  • Log level Information: Click to select normal log level
  • Log level Debug: Click to select debug log level; we may ask you to do this when diagnosing an issue
  • Log level Verbose: Click to select verbose log level; we may ask you to do this when diagnosing an issue
Version Check Runs an up-to-date check to see if the installed version of Prism for AL is the newest version available. If not, you should update to the latest version.
Enter License Open the License dialog.
About Displays information about Prism for AL. Please make sure to download a newer version of Prism for AL before the executable expires date.

Namespace name formatting options:

This combobox controls how object references are formatted.

Value Description
Source

Only show namespace names before object references, if they are written in the source code.

Source Prism
Customer Customer
Microsoft.Sales.Customer.Customer Microsoft.Sales.Customer.Customer
Qualified

Always show namespace names before object references, regardless of how the object references are written in the source code.

Source Prism
Customer Microsoft.Sales.Customer.Customer
Microsoft.Sales.Customer.Customer Microsoft.Sales.Customer.Customer
Unqualified

Never show namespace names before object references, regardless of how the object references are written in the source code.

Source Prism
Customer Customer
Microsoft.Sales.Customer.Customer Customer

The solution window opens once Prism has loaded a workspace. It consists of two or three tabs:

  • General: Module overview
  • Discovery: Package resolution overview
  • Code Graph: Graph generation status, graph server management, and metrics of the code graph. This tab is only visible with a code graph is being generated or has been generated.

Once you select an object, the solution window closes. Use the Solution button to open the solution page again.

The General tab contains a table of modules that Prism has tried to resolve:

Prism for AL workspace solution overview
Solution general tab.

If you see any parse errors on this page, please refer to the parse error troubleshooting section.

All data originates from app.json files for workspace folders and NavxManifest.xml files for packaged modules (.app files). Below we will refer to this data as module metadata. From the detail view we describe only special fields not directly copied from module metadata.

# Name Description
1 Search Substring search in columns: Publisher, Name and Version.
2 Topologic order (#) The topologic sort order deduced from the module dependencies.
3 Publisher The publisher name from the manifest.
4 Name The name of the module.
5 Version The version the module.
6 Constraint The aggregate version constraint by other modules of the workspace.
7 Origin Indicates whether the module is from a workspace folder or from a package.
8 Total object count Total number of objects found in the module.
9 Object count per object type Number of objects per type.
10 Dependency graph Opens the Module graph window highlighting the module.
11 Using Modules which this module depends on with contraints. Click a module to view its details.
12 Used By Modules (including actual version) which uses this module. Click a module to view its details.
13 Path The path app.json or NavxManifest.xml where the module is defined. Click to open in your default text editor.
14 Resource Exposure Policy Tri-state checkbox with following semantics:
  • Checked: Setting is defined and selected
  • Unchecked: Setting is defined and unselected
  • Filled: Setting is undefined

The Discovery tab contains a table of package files that Prism for AL has considered while loading:

Prism for AL workspace solution - discovery
Solution discovery tab.
# Name Description
1 Status One of the following:
  • Checkmark: Indicates this package is included in the solution.
  • (blank): Indicates this package was ignored.
  • Error cross: Indicates errors dealing with this file; maybe the file is not a package file or maybe it is a runtime package (Prism for AL cannot use these as the content is encrypted). An error columns gives details of the error.
2 Path The (virtual) path to modules here represented as app.json files and .app files.
3 app.json file This row represents the root of a Visual Studio Code project, here in the root directory. Click the row to view module details.
4 .app file included This row represents a package successfully included in the workspace. Click the row to view module details.
5 .app file ignored This row represents a package file that has been ignore. Typically because there are not dependencies to it or dependencies are ignored due to the Package resolution search depth. Click the row to view module details.

While generating a code graph, the Code Graph tab contains the generation status and metrics:

Prism for AL workspace solution - code graph generation
Solution code graph tab during graph generation.
# Name Description
1 Status Information about current phase and overall progress.
2 Metrics Various metrics of the generated code graph. The metrics are recorded by the export step, not the actual graph database.

Once the graph has been generated, the status section is replaced by Management:

Prism for AL workspace solution - manage code graph
Manage graph server.
# Name Description
1 Stop Stops the graph server service. This will disable all features that depends on the code graph. This is intended for emergency situations, only.
2 Restart Restarts the graph server service with the same graph database. This is intended for emergency situations, only.

The module graph visualizes all module dependencies of the current workspace. All information is deduced from app.json/ NavxManifest.xml metadata files. Depending on settings, the graph includes all kinds of module dependencies:
Prism for AL module dependency graph
Module dependency graph.
# Name Description
1 Graph Modules are nodes and dependencies are edges in the graph. Click a module to high-light the module and it's outgoing dependencies and its module details on the right. Use FN and MOUSE WHEEL to zoom in and out.
2 Module details Module details from the metadata file.
3 Layout algorithm The algorithm used to layout the graph. Experiment with the options to find the one that fit's your purpose best.
4 Direction The direction of the layout.
5 In-degree/out-degree Check this to annotate modules with the total number of in- and out-going dependencies.
6 Location Check this to annotate modules with location of the module in the file system.
7 Version constraint Check this to annotate dependencies with the version constraint specified.
8 Unused Check this to only show modules that are referenced by another module.
9 Unresolved Check this to include unresolved dependencies.
10 Propagated Check this to include propagated dependencies. In the example above, the dependency from VAT Group Management to Base Application is propagated via Application.
11 System Check this to include System module and all dependencies to it. (Basically all modules except those without platform element.)

Use the object index to get an overview of objects and search for specific objects:

Prism for AL object index
Object index.

Objects are presented in a (configurable) hierarchy with the objects as leaves:

# Name Description
1 Grouping level 1 The first grouping level is by default the module. Modules are presented with name followed by publisher.
2 Grouping level 2 The first grouping level is by default the object type.
3 Object The third level of the hierarchy is object. Objects are presented with an icon representing the object type, the object name followed by the object number.
4 Search Enter a filter expression to search for specific objects. The list is changed as you type. Object filter expressions can filter on both object name and object number.
5 Settings Opens the index settings dialogue.
6 Expand/collapse all Toggle button for expanding/collapsing all groupings.

Module context menu:

Menu item Description
Go to Module Opens the Solution and opens the module's detail view.

Object context menu:

Menu item Description
Find Usages Find usages of the object.
Find System Function Usages Opens the Find system function usages window where you can select which system functions to include in the search.
Explore Table Relations Enabled for tables, only. Opens the Explore table relations window with the current table as starting point.
Go to Object Definition in Visual Studio Code Enabled for objects defined in a workspace file, only (not objects defined in an included package.). Opens Visual Studio Code folder or .code-workspace depending on how Prism for was opened, and navigates to the object. If the folder or workspace is already open in Visual Studio, then the instance is reused. Notice that you can also navigate to a precise object location in Visual Studio Code from anywhere in the Object view.
Open in Text Editor Opens your default tool for .txt in a temporary file with the source code of the object.
Copy to Clipboard Copies the source code of the object to the clipboard.
Go to Module Opens the Solution and opens the detail view of the object's module.
Clear Codeline Selections Clears the current set of codeline selections.

Use the settings dialog to control grouping and sorting:

Prism for AL object index grouping and sorting
Object index groping and sorting.

Change settings as described below, then click somewhere else for the changes to take effect. Notice that these settings are per open workspace and they are not persistent (they are reset back to default next time you open Prism for AL.)

# Name Description
1 Hierarchy order Click the up/down arrows to dedice if module or type is the top grouping.
2 Enable/disable a level Use checkboxes to group by module, object type or both or even none.
3 Direction Check to sort this level ascending, uncheck to sort descending.
4 Sort By Modules may be sorted by one of:
  • Topology: The topological order induced by module dependencies.
  • Publisher: The name of the publisher
  • Name: The name of the module
Types are always sorted in the following order:
  1. Table
  2. TableExtension
  3. Page
  4. PageExtension
  5. PageCustomization
  6. Report
  7. ReportExtension
  8. Codeunit
  9. Interface
  10. XmlPort
  11. Query
  12. Enum
  13. EnumExtension
  14. Profile
  15. Dotnet
  16. PermissionSet
  17. PermissionSetExtension
  18. Entitlement
Objects may be sorted by either name or id.

This view is shown when it has been selected via the View selector. The object view presents the full details of the object as a logical structure using icons, colours, module annotations etc:

Prism for AL structured object view
Object view.
# Name Description
1 Declaration section shortcuts Links to sections of object content post-fixed with the number of declarations. Click the link to navigate to the first declaration of the kind. A link is only displayed when there are declarations of that kind. Trigger Events are only displayed when there are subscribers.
2 Object extensions List of objects extending this object. Click to navigate to the object.
3 Module annotation Object references have postfixed information about the module the object belongs to (publisher name and module name).
4 Semantic code colouring Identifiers in code are coloured based on their semantics. For example, built-in instance methods like PAGE.Update are coloured green in the code.

Events are highlighted with icons:

Prism for AL: Events are highlighted in object view
Object view event publishers and subscribers.
# Name Description
1 Yellow lightning symbol Event publisher.
2 Green lightning symbol Event subscriber.
3 Subscriber's publisher reference Click the subscriber identifier to navigate to the publisher.

When TransferFields is used on two different tables, a special context menu is available:

Prism for AL object view transferfields context menu
TransferFields context menu when tables differ.
Menu item Description
Show Inter-table Field Mappings Opens the Field transfer mappings window.

Identifiers that reference a declaration have tooltips and you can click to navigate to the declaration:

Prism for AL object view goto declaration
Object view – goto declaration.

Following navigation, a little red dot will high-light the navigation target. Also, the navigation history is updated, so hitting the back button after navigation will bring you back to the navigation source.

When clicking an identifier that resolves to a system function, a window with Microsoft's official documentation is opened in your default browser.

Identifiers that declare something, e.g. variables, procedures, fields etc, offer Find usages via left-click:

Prism for AL left-click declaration to find usages
Left-click declaration to find usages.

The default declaration context menu is:

Prism for AL default context menu
Default declaration context menu.
Menu item Description
Find Usages Find usages searches the whole workspace including packages for usages of the declaration and opens the Usages window.
Find Flows To Finds flows to the declaration and opens the Flows window. This menu item is only enabled when a code graph has been generated, see build graph.
Find Flows From Finds flows from the declaration and opens the Flows window. This menu item is only enabled when a code graph has been generated, see build graph.
Go to Source Changes view to Source view and positions cursor at the declaration.

Find flows to and Find flows from are enabled for the following kinds of declaration:

Declaration kind Find flows to Find flows from
Procedure yes yes
Trigger yes yes
Database Trigger Event yes yes
Field yes no
Enum Value yes no
Variable yes no
Parameter yes no
Return variable yes no
Text Constant yes no

Procedures (including event publishers and subscribers) offer additional functionality via the context menu:

Prism for AL procedure context menu
Procedure context menu.

The additions are:

Menu item Description
Copy Name to Clipboard Copies the name of the procedure, to the clipboard.
Copy to Clipboard Copies the source code of the procedure to the clipboard including annotations.
Open in Text Editor Opens your default text editor with the source code of the procedure.

A context menu is available anywhere in the object view, properties, code lines etc:

Prism for AL context menu available anywhere in object view
A context menu is available anywhere.
Menu item Description
Go to Source Changes view to Source view and positions cursor on the same line.
Go to Line in Visual Studio Code This menu item is available for objects defined in .al files in workspace folders, i.e. not in packages. Opens Visual Studio Code (if not already open with the current folder/workspace and navigates to the line where the function was invoked.

Code sections of procedures and triggers offer the following context menu:

Prism for AL code section context menu
Code section context menu.
Menu item Description
Copy Code to New Window Copies all code to a new Code fragment window.
Copy Code to Clipboard Copies all code to the clipboard.
Go to Source Changes view to Source view and positions cursor at the procedure or trigger.

Code lines of procedures and triggers can be selected and be actioned in various ways Left-click the area to the right of the vertical bar on the start and end line. The area will be marked with symbol, and the start and end indicators offer a context menu:

Prism for AL code line selection
Code line selection.
Menu item Description
Copy Code to New Window Opens the Code fragment window with the selected lines.
Copy Code to Clipboard Copies the selected code lines to the clipboard with context information.
Copy Code to Clipboard without Context Copies the selected code lines to the clipboard without context information.
Open Code with Default Text Editor Opens your default text editor with the code lines.
Clear Selection Clear the selection of code lines. You can also clear the start or end selection with a left-click.

Based on data in XLIFF files, Prism shows translations in place in the selected language. Hover over the translation symbol to see how there the translation originates. In case multiple translations are available for the same language, all translations are displayed in priority order with a 'disqualification' reason.

Prism for AL in place display of label translation
In place display of label translation with explanatory tooltip.

This view is shown when it has been selected via the View selector and is also the default view. The extended view is similar to the Object view but inlines items defined in the object's extensions:

Prism for AL extended view - extension
Extension.
Prism for AL extended view - extensions are inlined
Extended view of base object.
# Name Description
1 Control change action Here Add Controls Before corresponds to addbefore, meaning add controls before the anchor.
2 Anchor reference The base control to anchor the action, i.e. the control to add controls before. Click to navigate to the control in the base page.
3 Controls to add The controls to add before the anchor.
4 Inlined extension control The field added by the extension is displayed in the base page and before the anchor.
5 Anchor declaration The anchor control declared in the base page.
6 Extension arrow The arrow indicates that this control is defined in an extension. Click the arrow to navigate to the declaration in the extension object.

Notice that if multiple extensions try to e.g. add controls before a certain control, the outcome depends on the order in which the extension actions are applied. Prism applies changes in the topological order induced by the module dependencies, just like Business Central's runtime.

The source view is shown when it has been selected via the View selector. You can also get to the source view by other means:

The source view shows the object in plain text. Highlight any text and copy to clipboard with Ctrl+C or right-click to copy via the context menu:

Prism for AL source view
Source view with selected text and active context menu.

The dependencies view gives an overview of how other objects use the current object and how the current object uses other objects. The view is selected with the View selector and has sections for Used by (incoming references) and Using (outgoing references)

Hold the Shift key and select one or more columns to sort. Multiple click on the same column reverses the order.

Prism for AL dependencies view
Dependencies view.
# Name Description
1 Search field Enter a name and id search expression to narrow down the results. The filtering works against both object name and object number.
2 Used By Overview of how the current object is used by other objects. The title is postfixed with total count and optionally number of results filtered out.
3 Using Overview of how the current object uses other objects. The title is postfixed with total count and optionally number of results filtered out.
4 Module (grouping) Results are grouped by module.
5 Type The object type.
6 Id The object Id.
7 Name The object name.
8 Dependency types The type of object dependency.
9 Checkmark A checkmark indicates that the object, here Codeunit "Price Helper - V16" has at least one dependency to current object (Table Customer) of type OnAfterRename (database trigger event).
10 Used by object name functionality Click the object name to navigate. The full object context menu is available. Notice however, that Find usages works like a drill-down: Selecting Find usages on Codeunit "Price Helper - V16" will return all object dependencies to the current object (Table Customer) from Codeunit "Price Helper - V16".
11 Using object name functionality Click the object name to navigate. The full object context menu is available. Notice however, that Find usages works like a drill-down: Selecting Find usages on Enum "Price Calculation Method" will return all object dependencies from the current object (Table Customer) to Enum "Price Calculation Method.

The object outline is a tree structured index of the object contents and is both part of the workspace window and can also be opened in a separate window in several ways. This allows you to have outline windows open for multiple objects.

As part of the workspace window, the outline follows the current object when the windows was opened. When opened as a separate window, the window sticks to the object that was current/selected when opened.

Prism for AL: Structured object outline with filter applied
Object outline filtered to 'item'
# Name Description
1 Search field Enter a name and number search expression to find what you are looking for. Outline items can be filtered by name and/or number (when the item type allows, e.g. field numbers may be searched.) When an item is inside the filter, but a parent is not, the parent is greyed out.
2 Expand/collapse arrows Expand/collapse arrows appear when the cursor is in the left of the tree. Click to expand/collapse
3 Settings Opens the settings dialogue, see below.

The outline settings provides detailed configuration options:

Prism for AL: Object outline settings
Outline settings.

Here follows a description of the non-obvious settings:

# Name Description
1 Kinds Check to preceede each item with its kind, e.g. FIELD.
2 Types Check to show AL types for variables and parameters
3 Groups Check to add a grouping entry. E.g. triggers will be grouped under an entry TRIGGERS.
4 Extensions This setting is enabled in Extended view and for extensible objects, only. Check this setting to only show items that are inlined from extensions. See screenshot below.

When outline settings have checked Extensions, then only items inlined from extensions are displayed:

Prism for AL: Object outline extensions only
Filtered to show only items that are added by an extension (🠔 Extensions)

Click an item in the outline to navigate to the declaration in the current workspace view.

Right-click to activate the same context menu that is available in Object view and Extended view,

Overloaded procedures are marked with a counter and navigation arrows that indicate if more overloads exist either prior to or following a procedure:

Prism for AL: Overloaded procedure
Overloaded procedures

The code fragment window can be open from code sections or by selecing code lines. Use the fragment window to remember interesting code fragment for your own purpose or for sharing with a colleague.

Prism for AL: Code fragment
Code fragment window.
# Name Description
1 Origin Name of original procedure or trigger where the code lines were copied from. Click to navigate to the procedure or trigger.
2 Code Code with usual Object view features such as tooltips and go to definition links.
3 Origin source line link Link back to original line of code where this was copied from.
4 Notes Add notes to this code fragment.
5 Copy to clipboard Copy context, code and notes to the clipboard as plain text.

This dialog is invoked from the object context menu Find system function usages. The dialog allows you find where certain instance methods are called on the target object. You can think of usages being on the form TargetObject.SystemFunction, although the process of course also finds usages where the object is implicit as it is in with statements and when used without preceeding rec. via e.g. the SourceTable property.

Select which instance methods to search for (multiple selections are allowed):

Prism for AL: Select system functions to search for
Selection of system functions to search for.
# Name Description
1 Target object The object to search for calls to the system function.
2 Methods The methods to search for are presented as checkboxes and depends on the object type. For tables, the functions are grouped according to the CRUD classification:
  • Create
  • Read
  • Update
  • Delete
Use the search box to shorten the list of available methods.
3 Search button Runs the search process and opens the Usages window.

Find usages of can be invoked on declaration identifiers in multiple places:

The window groups result in a hierarchy and allows advanced filters and invocation of new Find usages searches:

Prism for AL: Usages
Usages with field filter.
# Name Description
1 Usage target The declaration searched for. Click to navigate back to declaration.
2 Heading The heading contains number of usages filtered out, if any. Click the collapse/expand button to collapse/expand all results.
3 Usage Click a usage to navigate.
4 Usage context When a usage is found in a declared context, e.g. within a procedure, the blue and bold font indicates that Find usages is available in the context menu.
5 Text filter Filter result lines by entering a substring search criterion.
6 Toggle filter options Click the expander to view additional filter options, if available. Additional filter options are available for these targets:
  • Table field: like in the above screenshot
  • Table: see example below
7 Settings Click to open the Settings window, which has several settings that influence this window.
8 Show where assigned and read Click this radio button to show all usages, i.e. where the field is assigned or read. Use detailed include options to narrow the results further.
9 Show where assigned only (…) Click this radio button to show where the field is assigned only. Use detailed include options to narrow the results further.
10 Save options Click the save button to set your default Include options for the currently selected radio button group. These settings will survive restart of Prism for AL.
11 Copy to clipboard Copies the filtered result to the clipboard.
12 Filter ratio bar Indicates the ratio of usages shown relative to the total number of usages found.

When the target of Find system function usages is a table, then the following filter options appear:

Prism for AL: Usages with table filter
Usages with table filter.
# Name Description
1 Temporary record filter options This filter is available when when searching system functions of a table object.
2 Show all usages (temporary or physical) Click this radio button when you want to show all usages.
3 Zoom in on physical usages Click this radio button when you want to focus on physical (not temporary) usages only. The trouble is that when a parameter to a procedure is declared as var (by-reference), then – whether or not the parameter is declared temporary or note – the procedure can be called with actual parameters that are both temporary and physical/normal. So the temporary declaration on var parameters cannot be trusted (it is not enforced at compile-time and also not at runtime). Therefore, if you want to be sure to include all physical usages, then you need to use the option Include all (whether declared physical or temporary). If you believe that all calls to procedures with temporary var parameters have actual parameters that are actually temporary, then you can select the option Only include if declared physical.

The Flows window displays contextualized code (syntax nodes) that may be reached from a certain declaration (flows from) or code that may reach a certain declaration (flows to).

Flows from and Flows to can be invoked from context menus on declaration identifiers:

We use the following types of flow nodes:

  • Flow nodes:
    • Syntax nodes: Elements from AL's syntax trees, such as statements, expressions, identifiers, and operators.
    • Non-syntax nodes: These are nodes that are not represented in AL's syntax, but still play a role in execution of AL code:
      • Runtime: Special nodes that represent a state in program execution, such as RunCodeunit, which represents the state that a codeunit must be run. In that way, runtime nodes provide the "glue" between calls to Codeunit.Run() and the Codeunit's OnRun trigger.
      • User: Represents the state where a user has interacted with Business Central. For example, an Action node represents a state when a user has clicked a button and a PageFieldValidation node represents a state where a user has entered data and left a field causing validation.
  • Context nodes: Context nodes show the syntactic context of flow nodes all the way to the module level. Some nodes are both context nodes and flow nodes, such as procedures. We use the flow node symbol for these.

Prism for AL: Flows
Flows to applied to an OnValidate trigger.
# Name Description
1 Declaration The declaration that was the subject of the find flows search. Click to navigate back to declaration.
2 In Flow / Out Flow The direction of the search.
  • In Flow: The search was Flows to.
  • Out Flow: The search was Flows from.
3 Filter message A message indicating the number of flow nodes currently displayed and how many are filtered away with the current settings.
4 Large result set message This message signals that the result set is large and refresh is slow as defined by settings. When this message occurs, window refresh has been changed to manual, and you need to click the refresh button after doing changes to filters and when changing the search field.
5 Contextualized flow nodes

The flow nodes of the search result in their syntactic context, so in a tree structure all the way up to the owning AL module. Syntax nodes within a code context (procedures and triggers) are ordered by the natural order of the source code, which corresponds to a downward flow within each code context. The ordering of context, e.g. modules, objects, object members does not have any semantic significance with regards to flow.

Click on any item to navigate.

Use the context menu to invoke Find Shortest Path or pin a node.

6 Collapse all nodes Collapses all nodes to the module level.
7 Collapse/expand to object level Expands modules and collapses everything else. Shows modules and objects.
8 Collapse/expand to object member level Expands modules and objects and collapses everything else. Shows modules, objects and object members (top-level declarations).
9 Expand down to pinned nodes Expands the paths down to pinned nodes.
10 Expand all nodes Expands the whole tree.
11 Settings Opens the Settings window. Flow related settings are found in the Find flows and Graph Database Serversections.
12 Filters Toggles the left-hand filter panel.
13 Search Filters the result using a substring search syntax.
14 Refresh view button Click to refresh the view following changes to filters and/or search string.
15 Find shortest path Use this menu to gain insight into the execution path between the declaration and this node. See below.
16 Pin/Unpin node Toggles whether this node is pinned or not.
17 Unpinned Uncheck this to view only pinned nodes and their ancestors.
18 Flow child nodes When unchecked, only the top-most flow nodes are shown. So if a procedure contains flow nodes, only the trigger will show. Nodes in the trigger body are filtered away.
19 Leading siblings When unchecked, the leading siblings are filtered away and what remains is the nesting structure, which is useful if you want to focus on under which circumstances (conditions of branching and repetitive statements) a flow may happen.
20 Main filter (dropdown) The main filter offers the following values:
  • General: This setting does not actually filter, hence: In case of flows from, the window displays all nodes that may be reached from the declaration. In case of flows to, the window displays all nodes that may be reached from the declaration.
  • User action: Filters to only show user actions, such as a user clicking a page action or a user triggering field validation when leaving a page field. This option is only available for flows to.
  • Event publisher: Filters to only show event publisher procedures (integration and business events). This option is only available for flows from.
  • CRUD: Filters to only show Create, Read, Update, or Delete (CRUD) nodes, i.e. table operations. This option is only available for flows from.

The result of selecting Find shortest path in the context menu of a flow node is that a new flow window is opened in a mode where:

  • Only nodes on a shortest path between the two flow nodes are displayed.
  • The ordering of the flow nodes is step-by-step in the order given by the path.
  • Flow nodes are numbered.
  • The same context may appear more than once (e.g. when codeunit A calls something in codeunit B, then something in codeunit C, then something in codeunit B again.)

Prism for AL: Shortest Path
Shortest path from an action subscriber procedure OnAfterModifySalesHeader.
# Name Description
1 Shortest Path Indicates that the window displays the shortest path from a selected node to the declaration node, when invoked from Flow to, and the shortest path from the declaration node to a selected node, when invoked from a Flows from. selected. Flow nodes are numbered with steps starting from 1 at the source of the path.
2 Source/target nodes The path's source and target nodes are marked with yellow background.
3 Step number Flow nodes are numbered with steps starting from 1 at the source of the path.

Free text search can be initiated via the menu or by shortcuts (Ctrl-F for searching current object and Ctrl-Shift-F for searching all objects). The search is line by line and allows the substring with wildcards syntax.

in the following example we search for captions that start with the text ledger entry. The first tab presented is the Plain tab, where the grouping is always module and object:

Prism for AL: Free text search plain view
Free text search plain view.
# Name Description
1 Search expression Enter search expression – allows the substring with wildcards syntax.
2 Scope Determines which objects to search:
  • All objects: Search all objects
  • Currently filtered objects: Search objects that are currently in the Object index filter.
  • Current object: Search the current object
3 Search/Cancel button This button toggles between Search and Cancel:
  • Search starts the search process on the search expression automatically pre- and postfixes a *.
  • Cancel stops the search process and shows the partial search result.
4 Results limit Select the max number of results you want the search process to return.
5 Plain tab Results are grouped by module and object.
6 Grouped tab Click this tab to view the results with a deeper grouping. This tab is available only when the grouping process has completed (lower progress bar).
7 Source line Source line within the scope mathing the search expression. Click to navigate.
8 Result count Number of source lines within the scope that matches search expression.
9 Copy to clipboard Copies the search result to the clipboard.

Once the grouping process has finished, the Grouped tab is ready:

Prism for AL: Free text search grouped view
Free text search grouped view.
# Name Description
1 Grouping Grouping is deeper and contains declaration path from result and upwards in the syntax tree.
2 Functionality Blue and bold identifiers in grouping headers offer context menu for Find usages.

The search event publishers window is available through the menu of the Workspace window. Use this window to search for event publishers (integration and business):

Prism for AL: Search event publishers by name
Search event publishers.
# Name Description
1 Search expression Enter a substring with wildcard search expression that will be matched against the event (publisher method) name.
2 Scope Select which objects to search (all or currently selected in Object index).
3 Search button The button is only available when a search expression has been entered. If you want to search for all event publishers, then Click to execute the search.
4 Search results Search results are grouped by module and object. Use the expander in the header to expand/collaps all.
5 Result (publisher) Click to navigate.
6 Copy to clipboard Copies search results to the clipboard.

The search fields window is available through the menu of the Workspace window. Use this window to search fields by name:

Prism for AL: Search fields by name
Search fields.
# Name Description
1 Search expression Enter a substring with wildcard search expression that will be matched against the field name.
2 Scope Select which objects to search (all or currently selected in Object index).
3 Search button The button is only available when a search expression has been entered. Click to execute the search.
4 Search results Search results are grouped by module and object. Use the expander in the header to expand/collaps all.
5 Result (publisher) Click to navigate.
6 Copy to clipboard Copies search results to the clipboard.

The search procedures window is available through the menu of the Workspace window. Use this window to search procedures (including event publishers and subscribers) by name:

Prism for AL: Search procedures by name
Search procedures.
# Name Description
1 Search expression Enter a substring with wildcard search expression that will be matched against the procedure name.
2 Scope Select which objects to search (all or currently selected in Object index).
3 Criteria Use the checkboxes to include/exclude as appropriate:
  • Normal procedures: Include normal procedures, i.e. procedures that are neither event pblishers, nor event subscribers
  • Event publishers: Include event publishers (integration and business)
  • Event subscribers: Include event subscribers
4 Search button The button is only available when a search expression has been entered. Click to execute the search.
5 Search results Search results are grouped by module and object. Use the expander in the header to expand/collaps all.
6 Result (publisher) Click to navigate.
7 Copy to clipboard Copies search results to the clipboard.

Explore table relations is invoked from the Object context menu.

The basic idea is simple: the selected table is opened and shown with all inbound and outbound table relations. The selected table is then "fully explored" in the 1st degree connections. However the related tables may themselves have further, yet unexplored table relations:

Prism for AL: Explore table relations
Explore table relations.
# Name Description
1 Node (table) Here the initial table on which the explore table relations was initiated.
2 Unexplored incoming table relations The Item Ledger Entry table still has 22 inbound table relations to be explored. See the node context menu below.
3 Unexplored outgoing table relations The Item Ledger Entry table still has 21 outbound table relations to be explored. See the node context menu below.
4 Edge Each edge in the graph represents that there is at least one table relation from the source table to the target table. Right-click to invoke context menu.
5 Layout algorithm Select a layout algorithm after your liking.
6 Direction Select the direction of the layout.
7 Detailed Check for detailed view (default) where counts of unexplored ingoing and outgoing relations is displayed.
8 Included objects List of included objects. See below for how object can be included and excluded again.
9 Excluded objects List of objects that have been excluded after having been included.
10 Selecting tables Select a single table by clicking on it in the diagram or in the Included objects list. You can select multiple tables by holding down the Ctrl key. To action selected objects, right-click to invoke the context menu (described below).
11 Redraw Force redraw of diagram.

Notice that nodes are draggable with the mouse. However, wait with fine-tuning layout positioning, as whenever a new table is added or removed from the diagram, it it is redrawn with the selected layout algorithm.

Edge context menu:

Menu item Description
Show Details Runs the find usages process to find all table relations from the source table to the target table.

Node context menu:

Menu item Description
Explore All Inbound Adds all tables that have table relations targeting are the table on which the context menu was invoked.
Explore Selected (Inbound) Like Explore all inbound, but allows you to select which tables to include.
Explore All Outbound Adds all tables that have table relations to the table on which the context menu was invoked.
Explore Selected (Outbound) Like Explore all outbound, but allows you to select which tables to include.
Explore All In/Outbound Add all inbound and outbound tables to the diagram.
Navigate to Object Navigates to the object.

Selected nodes context menu:

Menu item Description
Exclude X Selected Here X is the number of currently selected objects. Excludes the selected objects from the diagram and adds them to the Excluded objects list.
Exclude X Unselected Here X is the number of included objects that are currently not selected. Excludes the unselected objects from the diagram and adds them to the Excluded objects list.

The transfer fields mapping is available from Object view and Extended view when TransferFields has two different tables for source and target.

Use this window to see how fields are mapped. The mapping is sorted by field number, as this what the mapping is based on (not the field name). The following is a mapping of TransferFields(TimeSheetDetail) in table 5510 "Employee Time Reg Buffer":

Prism for AL: Transfer fields mapping
Transfer fields mapping.
# Name Description
1 Source object The source table for the mapping, i.e. where values are copied from. This is the argument to TransferFields, i.e. SalesHeader.
2 Target object The target table for the mapping, i.e. where values are copied to. This is the record on which TransferFields is called, i.e. SalesInvHeader.
3 Direction The direction of the TransferFields (from source to target).
4 Field number The field number of a field in the source and/or target tables.
5 Source name Name of field with the row's field number in the source table. This is left blank if the source table does not have any fields with that number.
6 Source type The type of the field in the source table. This is left blank if the source table does not have any fields with that number.
7 Target type The type of the field in the target table. This is left blank if the target table does not have any fields with that number.
8 Target name Name of field with the row's field number in the target table. This is left blank if the source table does not have any fields with that number.
9 Mapping indicator Indicates whether the field is mapped or not:
  • Black: The field is mapped (field number is present in both source and target)
  • Grey: The field is notmapped (either source or target does not have this field)
  • Red: The field is mapped and the types of the source and target fields differ.

The file explorer is available from the "File | Explore" menu. Use the file explorer to understand which files make up the workspace.

Prism for AL file explorer
File explorer.
# Name Description
1 Packages This is a "virtual directory" representing Prism for AL's package cache restricted to packages relevant for the currently open workspace.
2 Package file Package files have a context menu, see below.
3 Workspace This is a "virtual directory" that represents to root of one or more Visual Studio Code projects (directories with app.json files). For single directory projects, the workspace represents the directory. For .code-workspace projects, folders are represented as directories below workspace.
4 .al files Files with AL code (.al files) have the objects they contain as children.
5 Objects AL objects have a separate context menu.

File context menu:

Menu item Description
Open Text File Opens the file with your default text editor.
Open Opens the file with your default editor for the file extension.
Copy to Clipboard Copies the contents of the file to the clipboard.

AL object context menu:

Menu item Description
Go to Object Navigates to the object.
Copy to Clipboard Copies the object source code to the clipboard.

If Prism cannot parse (or index) a compilation unit for some reason, this is indicated in the Workspace window once the workspace has been loaded:

Prism for AL workspace with parse errors
Workspace with parse errors.
# Name Description
1 Error indicator This link is displayed only when there are parse errors. Click to open the Compilation unit errors window (see below.)
2 Error count Parse error count per module. This column is only displayed when there are parse errors.

Here is what the Compilation unit errors windows looks like:

Prism for AL compilation unit errors
Compilation unit errors.
# Name Description
1 Search Filters the result list to errors where the Message column contains the the substring entered. This is useful when there are many parse errors and you want to verify which errors are similar.
2 Error

Each error has a Path to the .al file relative to the workspace and a Message that explains the error.

The actual error in this case is a (new) property BrandNewProperty that Prism cannot yet parse. This may happen when Microsoft introduces a new property and Prism for AL is not yet updated to support this property. Parse errors are rare as we watch pre-releases via Microsoft's Ready! for Dynamics 365 Business Central program

Click on a row to show the Details.

3 Details This part of the window shows details of the error.
4 Error position When available, the position of the error is indicated with ^-------.
5 Source The source code is diplayed i grey until the point where parsing fails. This is to give context to the error.
6 Copy diagnostics info to clipboard Use this context menu to copy diagnostics info to clipboard. To report a bug, paste this information into the Feedback window.

If Prism encounters errors generating a code graph for some objects, this is indicated in the Workspace window once code graph generation has finished:

Prism for AL workspace with a graph generation error
Workspace with a graph generation error.
# Name Description
1 Error indicator This link is displayed only when there are graph generation errors. Click to open the Graph diagnostics window (see below.)

Here is what the Graph diagnostics windows looks like:

Prism for AL graph generation error
Graph errors.
# Name Description
1 Error table Errors are at object level, presented with module, object type and name. Click on a row to view the error details.
2 Error details

Call stacks for the error selected in the error table.

3 Copy to clipboard Copies diagnostics info for all object to the clipboard. To report potentially multiple bugs, paste this information into the Feedback window.
4 Copy diagnostics info to clipboard Use this context menu to copy diagnostics info of a single error to the clipboard. To report a bug, paste this information into the Feedback window.

Prism for AL Connector Visual Studio Code

Prism for AL Connector is our Visual Studio Code extension that allows you to navigate to Prism for AL from any line of code in Visual Studio Code.

Prism for AL Connector is available on Visual Studio Marketplace. Install from the Marketplace or directly from Visual Studio Code (search for extension prism-al).

The extension has a single configuration, Prism for AL exe file. Leave this setting blank if you have installed Prism for AL in the default location.

In Visual Studio Code, from any cursor position of an object in an .al file, right-click and select View in Prism for AL. This will:

  1. Start Prism for AL (if not already running)
  2. Open the folder or workspace in Prism for AL (if not already open)
  3. Navigate to the object and position closest to the cursor in Visual Studio Code

Command-line interface

The command-line executable, StaticalPrismCmd.exe is registered as a so-called execution alias by the MSIX installer, so by magic, if you type StaticalPrismCmd.exe in a command shell you will get the correct MSIX installed version regardless of the PATH environment variable.

For help, run StaticalPrismCmd.exe -h. You can also get help on the specific command like the report command: StaticalPrismCmd.exe -h report. Furthermore, you can get help on a specific report: StaticalPrismCmd.exe report onprem-usages -h.

You can specify a workspace as either a directory or a .code-workspace file.

When integrating a report into a Continuous Integration pipeline, consider using options --log-file and --strict.

Analyzes a workspace and produces a tab-separated cross-reference of object dependencies with dependency types. Use StaticalPrismCmd.exe -h report object-dependencies for available options.

Example: StaticalPrismCmd.exe report object-dependencies "C:\workspace\LearnPrism" -o "c:\tmp\object-dependencies.csv"

Analyzes a workspace and produces a tab-separated list of unreferenced objects. Use StaticalPrismCmd.exe -h report unreferenced-objects for available options.

Example: StaticalPrismCmd.exe report unreferenced-objects "C:\workspace\LearnPrism" -o "c:\reports\learn\object-dependencies.csv"

Analyzes a workspace, builds a code graph and produces a tab-separated list of references to procedures and objects that are OnPrem annotated. Use StaticalPrismCmd.exe -h report onprem-usages for available options.

Example: StaticalPrismCmd.exe report unreferenced-objects "C:\workspace\LearnPrism" -o "c:\reports\learn\onprem-usages.csv --log-file c:\tmp\onprem-usages.log --strict"

Opens the Prism for AL application on a workspace. If Prism for AL is already running, no new instance is used, If the workspace is already open, then it is not reopened. Use StaticalPrismCmd.exe -h open for all available options.

Example: StaticalPrismCmd.exe open "C:\workspace\LearnPrism"

Troubleshooting

Symptom: Solution shows unexpected unresolved modules:

Prism for AL with unresolved modules
Unresolved modules. The tooltip gives a hint to the reason.

The tooltip gives a hint to the reason. In this case, the Base Application and System packages are unavailable because they have not been downloaded from Visual Studio Code, so use the Visual Studio Command AL: Download symbols, then reload the workspace.

Click on a line to view details such as which dependencies made Prism for AL want to resolve this module.

Symptom: You opened a folder which is not a Visual Studio Code project folder, i.e. a folder with no app.json file directly in the folder, and the module is not listed in the Solution's General tab.

The cause is likely that the package is a runtime package. To verify this, check the Discovery tab:

Prism for AL solution discovery tab with runtime package error
Solution discovery tab with runtime package error.

Prism for AL cannot load runtime packages as they are encrypted, so the only remedy for this issue is to use a normal (not runtime) package, if possible.

Symptom: Solution shows a package with no objects, but you know the package contains objects:

Prism for AL solution discovery tab: package with no objects
Package without objects.

This is perfectly normal for dependency-propagation-only modules such as Application. If this happens for other packages that you know contain objects, then it is most likely because the package is a runtime package. When you use AL: Download symbols, then Visual Studio Code will download an .app file with symbol file with no objects. There is currently no way to decude that the downloaded .app file is a runtime package so Prism shows this as a package without objects. The only remedy for this issue is to publish a normal (not runtime) package.

Symptoms: The workspace window indicates compilation unit errors.

If a workspace compiles with the AL compiler in Visual Studio Code, Prism for AL should be able to parse and analyze it. To diagnose, do the following:

  1. Use AL: package to run the AL compiler in Visual Studio Code; if that fails, fix the error and reload the workspace.
  2. If you have changes workspace files in Visual Studio Code (or another tool), please reload the workspace.
  3. If the steps above do not explain or fix the issue, then please report a bug via the Feedback window or email us at feedback@stati-cal.com. See compilation unit errors for how to get the error details that you can include in your description.

Symptoms: The workspace window indicates graph errors.

If you encounter any graph errors, please report a bug via the Feedback window or email us at feedback@stati-cal.com. See graph errors for how to get the error details that you can include in your description.

Symptom: Navigation internally in Prism for AL or from Visual Studio Code to Prism for AL is inaccurate.

This can happen if you had Memory cache unchecked when you loaded the workspace and workspace files have changed since then. In this case the solution is to reload the workspace.

If you experience the symptom in other situations, please report a bug via the Feedback window or email us at feedback@stati-cal.com.

Symptom: The Control panel license heading is 'Community Edition', the license status indicates an error (red text, e.g. 'invalid' or 'expired') and the message in the lower part of the control panel also indicates an issue:

Prism for AL control panel with license issue
Control panel with license issue.

For details about the error, check out the tooltip on the license status as indicated in the screenshot above.

When the license is not valid, Prism for AL runs in a feature-limited mode until you paste in a valid license key.

If you have just entered the license, most likely you have not copied the whole license key, by accident copied an old key, or the license key is for Prism for C/AL instead of Prism for AL.

If the license has expired, please contact your license administrator.