Search code examples
microsoft-dynamicsdynamics-navmicrosoft-dynamics-navdynamics-nav-2016

How to take user input using C/AL in NAV 2016?


Suppose I want to write a simple addition program using C/AL in NAV 2016. How can I dynamically ask user to enter the two numbers?

In Microsoft Dynamics AX we use "dialog" class for this purpose.

I need some code reference or the description to approach such process.


Solution

  • In Dynamics NAV do not have something like Dynamics AX dialog class.

    In this case you need create a page with your fields to user complete the info. Then in other page call this new page to open it and the user can complete de info or add in MenuSuite to access.

    Example:

    Page 88000 Calculator enter image description here

    Variables

    enter image description here

    Action and Action code enter image description here enter image description here

    Page running

    enter image description here

    Then you can create a menuSuite for this page or write this code in other page to open it

    PAGE.RUNMODAL(88000);