How to: Install a Windows Client Control Add-in Assembly

Microsoft Dynamics NAV Windows client control add-ins are provided in one or more Microsoft Framework .NET–based assemblies, which are .dll type files. To run a control add from the Microsoft Dynamics NAV Windows client, the control add-in assembly must be installed on the computer on which the Microsoft Dynamics NAV Windows client is installed. In some cases during development, such as when you compile an object that uses a control add-in, the control add-in assembly must also be installed on the computer that is running the development environment.

You can install control add-ins the following ways:

  • Install the control add-in assemblies manually on the Microsoft Dynamics NAV Windows client or development environment computer.

    For more information, see To install control add-in assemblies on the Microsoft Dynamics NAV Windows client manually.

  • Install the control add-in assemblies on the computer that is running the Microsoft Dynamics NAV Server or in the database.

    The assemblies will be automatically deployed to the Microsoft Dynamics NAV Windows client computer. For more information, see Automatic Deployment of Control Add-ins.

To install control add-in assemblies on the Microsoft Dynamics NAV Windows client manually

  • On the computer that is running the Microsoft Dynamics NAV Windows client, copy the assemblies that contain the control add-ins to the Add-ins folder of the Microsoft Dynamics NAV Windows client installation.

    By default, the path of this folder is C:\Program Files (x86)\Microsoft Dynamics NAV\90\RoleTailored Client\Add-ins.

    Note

    You can also include assemblies in a subfolder of the Add-ins folder. This can be useful if you have multiple assemblies and dependencies.

Automatic Deployment of Control Add-ins

If a control add-in has the same name as the assembly, the system can automatically deploy control add-in assembly, and any associated files, to the computer running the Microsoft Dynamics NAV Windows client. There are two ways that you set up the automatic deployment of a control add-in:

  • You can install the control add-in assembly directly on the computers running the Microsoft Dynamics NAV Server

  • Or you can import the control add-in assembly into the database.

When an operation from the Microsoft Dynamics NAV Windows client client requires a control add-in, such as running a page that contains the control add-in, the control add-in is deployed as follows:

  1. The client looks for the control add-in assembly in the local Add-ins folder (by default, C:\Program Files (x86)\Microsoft Dynamics NAV\90\RoleTailored Client\Add-ins).

    • If the assembly is available, it is used.

    • If the assembly is not available, the client requests the assembly from Microsoft Dynamics NAV Server.

  2. The Microsoft Dynamics NAV Server looks for the control add-in assembly in the local Add-ins folder (by default, C:\Program Files\Microsoft Dynamics NAV\90\Service\Add-ins).

    • If the assembly is available, it is deployed to the Microsoft Dynamics NAV Windows client computer.

      The control add-in is installed in the %TEMP%\Microsoft Dynamics NAV\Add-Ins folder of the user who is running the client.

    • If the control add-in assembly is not there, the add-in is deployed from the database to the Microsoft Dynamics NAV Windows client.

  3. The control add-in assembly is streamed from the database to Microsoft Dynamics NAV Server instance and eventually the Microsoft Dynamics NAV Windows client computer.

    On the Microsoft Dynamics NAV Windows client computer, the control add-in is installed in the %TEMP%\Microsoft Dynamics NAV\Add-Ins folder of the user who is running the client.

The deployed assembly will be then be used whenever the page is run until the control add-in has been updated with a version change.

If the control add-in assembly is updated and its version number changes, Microsoft Dynamics NAV Server will deploy the updated assembly to the client computer the next time that the client requests the assembly. The updated assembly is put in a subfolder of the %TEMP%\Microsoft Dynamics NAV\Add-Ins folder, where the subfolder has the assembly's version number as its name. This implementation means that you do have to remove the older versions of assemblies that are stored on the client computer.

The process is similar when the development environment requires a control add-in, for example, when you compile an object. the control add-in assembly will be deployed to the local temporary folder for the current user on the computer that is running the development environment.

Note

To be deployed automatically, a control add-in must have the same name as its assembly and the assembly must comply with the following Microsoft Dynamics NAV Server configuration settings: Chunk Size, Max Upload Size, and Prohibited File Types. For more information about these settings, see Configuring Microsoft Dynamics NAV Server.

To install the control add-in on Microsoft Dynamics NAV Server

  • On the computer that is running the Microsoft Dynamics NAV Server, copy the assembly that contains the control add-in to the Add-ins folder of the Microsoft Dynamics NAV Server installation.

    By default, the path is C:\Program Files\Microsoft Dynamics NAV\90\Service\Add-ins.

To import the control add-in to the database

  1. Create a compressed (.zip type) file that contains the control add-in assembly files in the desired folder structure.

  2. You can import the compressed (.zip) file when you register the control add-in from the Control Add-ins page in Microsoft Dynamics NAV. In the Search box, enter Control Add-ins and then choose the related link.

  3. In the Control Add-ins window, choose New, and then in the Control Add-in Name column, enter the control add-in name. In the Public Key Token column, enter the public key token that you obtained earlier.

  4. Choose Import.

  5. In the Import Control Add-in Resource window, locate the.zip file, and then choose Open.

  6. Choose the OK button to close the Control Add-in page.

For more information about registering a control add-in, see How to: Register a Windows Client Control Add-in.

Tip

You can also register the control add-in, import and manage the files by using the New-NAVAddin cmdlet, Set-NAVAddin cmdlet, Get-NAVAddin, or Remove-NAVAddin cmdlets from the Microsoft Dynamics NAV 2016 Administration Shell.

See Also

Tasks

How to: Set Up a Windows Client Control Add-in on a Page
How to: Install a Windows Client Control Add-in Assembly
Walkthrough: Creating and Using a Windows Client Control Add-in

Concepts

Installing and Configuring Windows Client Control Add-ins on Pages
Developing Windows Client Control Add-ins
Installing and Configuring Windows Client Control Add-ins on Pages
Windows Client Control Add-in Overview