I always wanted to blog about myself, but humble as I am I never got around to do that. Image may be NSFW.
Clik here to view.
But now I have an excuse.
When the Role Tailored Client was introduced in 2009 one of the things that is missing from the UI was the ability to Mark some records and filter on Marked Only records. This is usefull when you want a subset of your data with records that have no common value to filter on.
In the Classic Client, now Development Environment, you can find the functions here:
Image may be NSFW.
Clik here to view.Image may be NSFW.
Clik here to view.
However, this feature was discontinued from the IU, but not from C/AL.
In the C/AL Symbol Menu it is still possible to Mark records and filter them.
Image may be NSFW.
Clik here to view.
So let’s see what happens if we use that in a Page step-by-step. We’ll use the Customer List (Page 22)
Step 1 – Add a new Action Category (Optional)
To make it easy for end users to find the options we’ll start by adding a category for the actions we are going to add later.
Image may be NSFW.
Clik here to view.
Note that in order to add a new Category you need to also add the default ones. In this case we will work with Category4.
Step 2 – Add Actions with the correct properties
We add three actions in the ActionItems category
Image may be NSFW.
Clik here to view.
And we assign a Name, Caption, Image and PromotedCategory. I also choose to make them big and promoted.
Image may be NSFW.
Clik here to view.
Step 3 – Add C/AL Code
We add the C/AL commands to the actions
Image may be NSFW.
Clik here to view.
Note that we use the reverse value to toggle the values on and off
Step 4 – Add a column indicator
To make is easy for users to see if a record is marked or not we add a new column to the page with Mark as the source expression
Image may be NSFW.
Clik here to view.
The Result
When we run the page you see that we can Mark records which will be indicated in the new column, filter on them and easily clear the Marks.
Image may be NSFW.
Clik here to view.
TIP: Copy/Paste
Since we did not use any variables or functions we can just copy/paste the actions around to any other page, as long as the ActionCategoryML does not conflict with existing values.
Enjoy
Image may be NSFW.
Clik here to view.

Clik here to view.
