Bug in NAV 2013 R2 preventing correct execution of GETRECORD, SETSELECTIONFILTER and it's workaround
Yesterday I've discovered a bug in NAV 2013 R2 (I used build 7.10.37221) that results in inappropriate execution of GETRECORD and SETSELECTIONFILTER functions.
Problem description:
Both GETRECORD and SETSELECTIONFILTER always retrieve first record from SubPage despite other record is selected.
For demo of the bug I've copied Sales Order page with SubPage, removed unnecessary controls and created two actions:
- GETRECORD
- SETSELECTIONFILTER
with following code:
Both GETRECORD and SETSELECTIONFILTER retrieved first line of the document despite third one was selected. So the bug is that whichever record is selected in SubPage both functions always retrieve first record.
Workaround
After few attempts to find out what's wrong I discovered that workaround is very simple - both functions work correctly when I place any code (or even empty comment) to OnAfterGetCurrRecord() trigger of SubPage:
I hope this bug will be fixed soon :)
Comments
-
-
-
Hi, as you can see I used build 37221, so I would recommend to upgrade NAV platform to this build and then apply workaround.
-
this solution seems to be not working always.
Nav build 36366
Please advise whether its fixed in any recent release.
-
Thanks for the advice. Workaround also works in NAV2015, where the bug is still (or again?) present.
-
Many thanks for this ! Help me to resolve a bug when printing/navigating in FR bank module...
(the "bordereau" for connaisseurs...)

Like
Report
*This post is locked for comments