Reference manual

Interop References page

The Interop References page of the Workspace window lists every DotNet, Automation and OCX type the workspace uses, one row per type. Each type is rated for a move to Business Central online, which runs no .NET, COM or OCX, and named with its AL replacement where one is known. A plan by object shows what each object needs before it can move.

Opening the Interop References page

  • Select Interop References in the workspace window's navigation rail.
  • In Universal Search, type interop and choose the page under Pages.

The page is listed when Show Interop References page is on; see Hiding the page.

Scanning the workspace

The page scans the workspace the first time you open it: global variables, procedure and trigger locals, parameters and return values. It counts how often each variable is used in code.

StatusMeaning
Scanning workspace…, then Scanned N of M objectsThe scan runs. The page's dot in the navigation rail is amber.
The listsThe scan is done. The dot is green.
Scan aborted or Scan failed: …, with Open this page again to rescan the workspace.The scan did not finish. Leave the page and open it again to rescan.
No .NET / COM automation dependencies and This workspace is interop-free.The workspace uses no interop types.

A finished scan is kept while the workspace window is open, so leaving the page and coming back keeps the search and the sort.

By type

Prism for C/AL Interop References page by type, with a type selected and its details
1 2 3 4 5 6 7 8 9 10 11
Interop References by type, with a type selected.
#NameDescription
1Migration Risk LegendHover to read what each risk level means. See Risk levels.
2Risk stripThe number of types at each level, High, Unknown, Medium and Low, each segment as wide as its share. Select a level to list only its types; select it again to list all. One level filters at a time.
3AL replacement knownN of T types · K without one: how many types have a known Business Central replacement, and how many need a design decision.
4InventoryTypes, objects and references, and how many run on the client, are OCX, have events, are signed, are .NET interop and are native COM. Names how many objects could not be scanned, if any; the log has the details.
5By type / By objectBy type: one row per interop type, with a detail pane for the selected type. By object: what each object needs; see By object.
6SearchMatches types, assemblies, objects and variables. See Search and filters.
7Filter by kind and object typeOpens the filters for kind, object type and object IDs. See Search and filters.
8CountHow many types the search and filters leave, such as 12 of 40 types.
9Summary / DetailCopy the list to the clipboard; see Exports.
10TypesOne row per type; see Type columns.
11Detail paneThe selected type; see Type details.

Type columns

ColumnShows
RiskHigh, Unknown, Medium or Low.
TypeThe .NET class, or the Automation or OCX class.
Library or assemblyThe .NET assembly or the COM type library.
KindDotNet, Automation or OCX.
ObjectsHow many objects declare a variable of the type.
VariablesHow many variables have the type.
UsesThe uses of those variables in code.
Runs onWhere the type runs, such as Client or Server.
AL replacementThe known Business Central replacement, if any.

Select a header to sort by it, and again to reverse; an arrow shows the order. Count columns sort largest first. By default the list runs from High to Low risk, then by most objects.

A use is a reference to the variable in code. A variable with no uses reads unused: delete it before migrating. A WithEvents variable with no uses in code reads events only and does not count as unused.

Type details

Prism for C/AL Interop References detail pane for a selected type, with its risk, AL replacement, identity and the objects that use it
1 2 3 4
The detail pane of a type with a known AL replacement.
#NameDescription
1Risk and reasonThe selected type's risk level, its name, library and kind, and why it has that level. An unidentified Automation server is marked Unknown Automation Server.
2AL replacementThe Business Central replacement, or None known: this type needs a design decision.
3IdentityCLSID, Server, .NET and Reference as the objects declare it. The copy button copies the reference, version, public key token and CLSID.
4Used inUsed in N objects · M variables · K uses, then each object with Go to, and under it each variable: its name, scope such as Local in OnRun · WithEvents · No Dispose, its uses and where it runs.

When the search and filters leave no type, the detail pane reads No type is listed: change the search or filters.

Risk levels

Every reference has to be rewritten for Business Central online; the level ranks the rewrite.

LevelTypesWhat it takes
HighOCX controls, and .NET that runs on the client (Runs on Client or Mixed).The web client hosts neither, online or on-premises: a JavaScript control add-in or a server-side rewrite.
UnknownAutomation whose COM server the exported objects do not name.Re-export the objects on a machine where the server's type library is registered, or register the class on this machine, so Prism can identify it.
MediumCOM Automation servers (AL has no Automation type), and server-side .NET WithEvents.Native AL types, a JavaScript control add-in or an external service.
LowServer-side .NET, and .NET assemblies registered for COM.Online, native AL types or an external service; on-premises, an extension that targets OnPrem can still reference the assembly.

NAV writes Unknown Automation Server into the objects it exports when the server is not registered. The objects still carry the class CLSID, so Prism identifies the server on a machine where that class is registered.

By object

Prism for C/AL Interop References page by object, with an object expanded
1 2 3 4 5 6
The plan by object.
#NameDescription
1PlanObjects to change, how many need a redesign, need an external service or are covered by AL types, and how many unused variables to delete first, over the objects the search and filters list.
2PlanCopies the plan, one row per object and type. See Exports.
3ObjectRisk dot, name, and a caption such as Codeunit 50102 · 6 variables · 4 types · 2 unused.
4VerdictWhat the object needs; see the table below.
5Go toOpens the object on the Objects page.
6TypeA type the object uses, with its uses and replacement, such as XmlDoc · 1 use → and the AL type, … · no AL replacement, or unused · delete. Its variables are listed under it.
VerdictWhen
Needs a redesignThe object uses a type at High or Unknown risk.
AL types cover itEvery type the object uses has an AL replacement.
Needs an external serviceAny other object.

Search and filters

Prism for C/AL Interop References filter popup with kind, object type and object ID filters
1 2 3 4
The filters, open under Filter by kind and object type.
#NameDescription
1SearchMatches types, assemblies, objects and variables.
2KindThe interop kinds to list, with All and None.
3Object typeThe object types to list, with All and None.
4Object IDsID ranges to list, such as 50100..50199, 50300.

The search box matches types, assemblies, objects and variables, a moment after you stop typing. A type whose name, assembly or reference matches keeps all its objects; otherwise only the objects whose name or variables match are kept.

FilterChoices
KindDotNet, Automation and OCX, with All and None.
Object typeCodeunit, Table, Page, Report, XmlPort, Query, Form, Dataport and MenuSuite, with All and None.
Object IDsID ranges such as 50100..50199, separated by , or |; - also marks a range, and ranges can be open-ended.

The search and filters apply to both views, to the counts and to the exports.

Exports

Each export copies tab-separated text with a header row to the clipboard, following the search and the filters. Paste it into a spreadsheet.

ExportRowsColumns
Summary (By type)One per typeType, Kind, Assembly, Objects, Variables, Uses, Unused, RunOn, DotNetAssembly, DotNetClass, RuntimeVersion, AssemblyLocation, Events, SuppressDispose, Unidentified, Risk, ALReplacement
Plan (By object)One per object and typeObjectType, ObjectId, ObjectName, Verdict, Type, Kind, Assembly, Risk, Variables, Uses, Unused, RunOn, ALReplacement
Detail (both)One per variableObjectType, ObjectId, ObjectName, Scope, Variable, Kind, Type, Assembly, RawRef, RunOn, WithEvents, SuppressDispose, Uses, DotNetAssembly, DotNetClass, RuntimeVersion, AssemblyLocation

Plan the interop work for a move to Business Central online

Use this to size and order the interop work before a move to Business Central online.

  1. Open the Interop References page and wait for the scan to finish.
  2. Select By object. The plan line counts the objects to change and the unused variables.
  3. Delete the variables marked unused · delete first: select Go to on their object.
  4. Open Filter by kind and object type and type your own ID range under Object IDs to leave out standard objects.
  5. Select Plan to copy the plan, and paste it into a spreadsheet to assign the work.

Find the objects that use a type

  1. Select By type and type part of the type or assembly name in the search box.
  2. Select the type. The detail pane lists each object that uses it, with its variables.
  3. Select Go to on an object to open it.

Hiding the page

To remove the page from the navigation rail, turn off Show Interop References page on the Settings page. It is on by default, and the change applies at once.