O'Reilly logo

Extending Microsoft Dynamics NAV 2016 Cookbook by Alexander Drogin

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Linking add-ins with the database

The current recipe will cover the topic of creating a custom textbox control bound to a database field. Such control can be linked with a table field via the standard NAV property, SourceExpr. Any changes made by the user in a control linked to a table field are automatically reflected in the database.

How to do it...

  1. Run Visual Studio and create a Class Library project. Choose to create a new solution and enter NavDatabaseFieldControl as the name of the project.
  2. Rename the class Class1 in the solution explorer. Assign a new name, DatabaseFieldControl, and accept renaming all code references.
  3. In the solution explorer window, add references to assemblies Microsoft.Dynamics.Framework.UI.Extensibility.dll and System.Windows.Forms ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required