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

Announcements

No record found.

News and Announcements icon
Community site session details

Community site session details

Session Id :
Microsoft Dynamics GP (Archived)

VS Tools for GP: AfterModalDialog Responses are Readonly

(0) ShareShare
ReportReport
Posted on by 1,897

Hi,

I've added additional validation to the Project Maintenance window and trying to prevent users from saving it before correcting those errors.  When user closes the window with some changes in it, GP will prompt "Do you want to save changes". Upon clicking "save", my validation runs and if validation fails, I need to cancel the save operation and let user correct the error. we can achieve this in VBA by updating the Modal Dialog response to "Cancel", but VS tools for GP's AfterModalDialog event responses are Readonly and thus it's making it impossible to cancel the event.

Any Ideas?

Regards,

Jothikrishnan

*This post is locked for comments

  • Suggested answer
    Shyam Nath Profile Picture
    505 on at

    I think it will work if you change your validation from AfterModalDialog to BeforeSaveRecord event.

  • Jothi Krishnan N Profile Picture
    1,897 on at

    Thank you Shyam. I think I've tried that already and didn't work out in my case, but let me double check and update here.

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 August Top 10 Community Leaders

These are the community rock stars!

Leaderboard > 🔒一 Microsoft Dynamics GP (Archived)

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans