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 :
Small and medium business | Business Central, N...
Suggested Answer

Unable to validate condition if user uses next or previous button on card ribbon

(0) ShareShare
ReportReport
Posted on by 45

I used some validation on a card page inside an OnOpenPage trigger and it is it working fine until I start using previous and next button within ribbon on card page.

Any suggestions to make it work

I have the same question (0)
  • Suggested answer
    IB-29041624-0 Profile Picture
    1,189 Moderator on at

    When you move between records the page is not opened again so your "OnOpenPage" trigger will not be executed as a result for that.

    You need to use the "OnAfterGetRecord" trigger to have something executed when you move between records in a page.

  • Aditya raut Profile Picture
    45 on at

    Thanks NorthW , but I have already tried "OnAfterGetRecord" but it is not working correctly for my validation

    Basically I'm making Editable property to false for it but no luck

  • IB-29041624-0 Profile Picture
    1,189 Moderator on at

    Maybe you can share your code ?

  • Aditya raut Profile Picture
    45 on at

    pastedimage1639573326099v2.png

    So this is the condition and if it is correct then I need this editable property of page to false.

    But even if the condition validates page is still editable.

    However this condition works on "OnOpenPage" trigger but that previous and next button ruins functionality

  • Lars Lohndorf-Larsen Profile Picture
    Microsoft Employee on at

    Hello,

    I think you are out of luck on this one. According to this:

    github.com/.../1664

    Quite: "We do not support dynamic changes to the page Editable property, except via CurrPage.Editable(FALSE) in OnOpenPage.".

    I will watch here in case someone else has some ideas. Maybe you can change Editable for groups or fields, but I could also not find any ways to do that. Sorry I dont have better advice.

  • Suggested answer
    YUN ZHU Profile Picture
    101,414 Super User 2026 Season 1 on at

    Hi, Is it possible to try to close the current page and open a new page?

    A simple example:

    https://yzhums.com/16756/

    Hope this will help.

    Thanks.

    ZHU

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

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Stars!

Meet the Microsoft Dynamics 365 Contact Center Champions

We are thrilled to have these Champions in our Community!

Congratulations to the April Top 10 Community Leaders

These are the community rock stars!

Leaderboard > Small and medium business | Business Central, NAV, RMS

#1
OussamaSabbouh Profile Picture

OussamaSabbouh 2,216 Super User 2026 Season 1

#2
YUN ZHU Profile Picture

YUN ZHU 1,471 Super User 2026 Season 1

#3
AndrewThomas81 Profile Picture

AndrewThomas81 1,369

Last 30 days Overall leaderboard

Featured topics

Microsoft Training Manuals

Product updates

Dynamics 365 release plans