1. Describe the bug
Page.SetSelectionFilter(var Record: Record) method does not update properly the Record when changing from multiple selection in a list to single line selection in the same list .
2. To Reproduce
Steps to reproduce the behavior:
- Go to Items List Page in Dynamics 365 Business Central
- Select 3 item lines, for example , with No: 1010, 1011, 1012
3 Execute the action Actions->Functions> Calculate Counting Period-
The action is executed successfully for the selected lines,
- Deselect the lines with No.: 1010 and 1011 and maintain selected the line with No. 1012.
5 .Execute the action Actions->Function> Calculate Counting Period. This action is not executed for the selected line, it is executed for the line with No. 1011, that did not remain selected.
3. Expected behavior
When a user selects a set of records on a page, Page.SetSelectionFilter(var Record: Record) method refers to these selected records in Record parameter.
If we deselect some of these records and maintain selected only one of the initial set of the records , and call the method Page.SetSelectionFilter(var Record: Record) , Record parameter is expected to refer to the only selected record.
4. Actual behavior
When a user selects a set of records on a page, Page.SetSelectionFilter(var Record: Record) method refers to these selected records in Record parameter.
If we deselect some of these records and maintain selected only one of the initial set of the records , and call the method Page.SetSelectionFilter(var Record: Record) , Record parameter does not refer to the record that is seleted. It refers to one of the initial set of records that have been deselected.
5. Versions: