Tip: add "button" to Report Request Page

Miklos_Hollender
Miklos_Hollender Member Posts: 1,598
edited 2020-02-05 in NAV Tips & Tricks
Make a text constant with the name of the "button". Add a new field to the Request Page. SourceExpression is this text constant. Name and Caption empty, as in '', empty string, two apostrophes. Write your code into the OnDrillDown trigger. It will make the SourceExpression appear much like a hyperlink, the user clicks it, the code is ran.

Confirmed in NAV2016. Not sure about Business Central / AL.

Example use case: autofilling some fields/filters.

Answers

  • kriki
    kriki Member, Moderator Posts: 9,121
    Also works in BC! I am using this trick since quite some time!
    Regards,Alain Krikilion
    No PM,please use the forum. || May the <SOLVED>-attribute be in your title!