Skip to main content

Notifications

Small and medium business | Business Central, N...
Suggested answer

How to replace dialog.input in business central ?

Posted on by 10

Hello,

We used to use Dialog.INPUT in Microsoft Dynamics Nav but now it seems that Dialog windows are only for output, not for input. How can we ask the user a very basic question in business central ?

Thanks a lot.

  • Toni Sala Profile Picture
    Toni Sala 10 on at
    RE: How to replace dialog.input in business central ?

    Thanks a lot ZHU.

    Kind regards,

    TONI.

  • Toni Sala Profile Picture
    Toni Sala 10 on at
    RE: How to replace dialog.input in business central ?

    Thanks a lot Inge,

    Everything seems to be ok now.

    Kind regards,

    TONI SALA.

  • Suggested answer
    YUN ZHU Profile Picture
    YUN ZHU 73,472 Super User 2024 Season 2 on at
    RE: How to replace dialog.input in business central ?

    Hi, here are two simple examples that hopefully give you some hints.

    https://yzhums.com/17574/

    https://yzhums.com/16284/

    Thanks.

    ZHU

  • Suggested answer
    Inge M. Bruvik Profile Picture
    Inge M. Bruvik 32,748 Super User 2024 Season 1 on at
    RE: How to replace dialog.input in business central ?

    age 50102 "Dialog"
    {
        Caption = 'Dialog';
        PageType = StandardDialog;
        SourceTable = "Integer";
        SourceTableView = where(number = filter(1));
    
        layout
        {
            area(content)
            {
                field(MyInputText; MyInputText)
                {
                    Caption = 'Give me the value';
                }
            }
        }
        var
            MyInputText: text;
    
    }
    

    I guess that depends what you wanna do with the data. I usually just keep the input in variables on the page until i decide what to do with them.

    You can use the integer table as the data item for the page and set tableview to integer 1.

    Here is a small sample:

  • Toni Sala Profile Picture
    Toni Sala 10 on at
    RE: How to replace dialog.input in business central ?

    Thanks a lot Inge,

    Does it mean that we have to create a Temp table to store the value and develop some code to get this value or is there another way to do this ?

    Thanks again.

  • Suggested answer
    Inge M. Bruvik Profile Picture
    Inge M. Bruvik 32,748 Super User 2024 Season 1 on at
    RE: How to replace dialog.input in business central ?

    The way to do it is to create a page of type StandardDialog there you can have fields both for output and input. A little more work than it used to be in C/AL.

    docs.microsoft.com/.../devenv-page-types-and-layouts

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

December Spotlight Star - Muhammad Affan

Congratulations to a top community star!

Top 10 leaders for November!

Congratulations to our November super stars!

Community AMA December 12th

Join us as we continue to demystify the Dynamics 365 Contact Center

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 291,240 Super User 2024 Season 2

#2
Martin Dráb Profile Picture

Martin Dráb 230,149 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans