web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Microsoft Dynamics AX (Archived)

AX2012R2 Info message with checkbox

(0) ShareShare
ReportReport
Posted on by

Hi 

i want to send a user on a specifit action an info message  "hey watch out" (this works) and then a check box like "i read" and with out checking, the user cant close the infomessage with out checkning/  cant continue work. 

thx

Pirmin

*This post is locked for comments

I have the same question (0)
  • Verified answer
    Community Member Profile Picture
    on at

    Hi Pirmin,

    I think this will help you

    Dialogbutton db;

    db = box::yesNo( "hey watch out", dialogButton::No);

    It will show a dialog box with yes and no buttons based on button clicked you can go for next step

    if(db == dialogButton::yes)

    {

    }

    else

    {

    }

  • Verified answer
    Jonathan  Halland Profile Picture
    11,310 on at

    HI Pirmin. If you want anything more complex than a simple yes no, you will have to build up a dialog in code:

    static void dialogExample(Args _args)

    {

       Dialog      dialog;

       DialogField field;

       ;

       dialog = new Dialog("Example");

       dialog.addText("hey watch out:");

       field = dialog.addField("NoYesId"); // Use a type with a proper label

       dialog.run();

       if (dialog.closedOk())

       {

           info(field.value());

       }

    }

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

Season of Sharing Community Challenge Winners!

Congratulations to our community stars!

Women in Power Builds Momentum

Expanding mentorship, skilling, and AI innovation

Congratulations to the June Top 10 Community Leaders

These are the community rock stars!

Leaderboard > 🔒一 Microsoft Dynamics AX (Archived)

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans