Skip to main content

Notifications

Announcements

No record found.

Microsoft Dynamics AX (Archived)

Accessing a grid form from dialogue

Posted on by 5

Hi All, 

I have a form that fetches data from  table. I want to access or open this form from dialogue. 

Basically I am trying to create a link in the dialogue so that when I click the link in the dialogue it should open the form. 

Any help or pointers on how to do this in the x++

Thanks

Rafi...

*This post is locked for comments

  • Mark Boy2 Profile Picture
    Mark Boy2 490 on at
    RE: Accessing a grid form from dialogue

    Hi, Rafi1985

    WMSJournalTable WMSJournalTable;

    SysInfoAction_Formrun sf = SysInfoAction_Formrun::newFormname(formstr('wmsjournaltable'));

    select WMSJournalTable

       where WMSJournalTable.journalId != "";

    sf.parmCallerBuffer(WMSJournalTable);

    sf.run();

  • Blue Wang Profile Picture
    Blue Wang on at
    RE: Accessing a grid form from dialogue

    Hi Rafi,

    Yes,I agree with Brandon’s suggestion that you can quickly meet your needs with a button or MenuItem.
    Some different links.

    https://dynamicsuser.net/ax/f/technical/33896/a-button-code-to-open-a-new-form

    https://community.dynamics.com/ax/f/microsoft-dynamics-ax-forum/129267/how-to-open-form-via-button

    I hope it will help you.

  • Suggested answer
    BrandonSA Profile Picture
    BrandonSA 1,669 on at
    RE: Accessing a grid form from dialogue

    Hi

    There are many ways to do this.

    A simple way would be to add a button to your dialog, like a menu item.

    Here is how you would do that :

    To create a dialog: dynamicsaxswapt.wordpress.com/.../

    To add a button: stackoverflow.com/.../how-to-add-a-button-to-a-dialog-and-create-a-method-for-the-click-event.

    If you really wanted to go for a link, you could just override the clicked() method and call the menu item from there.

    Try to keep your forms looking like the rest of Ax though.

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!

Tips for Writing Effective Suggested Answers

Best practices for providing successful forum answers ✍️

Leaderboard

#1
André Arnaud de Calavon Profile Picture

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

#2
Martin Dráb Profile Picture

Martin Dráb 230,198 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans