Setting the Tracking Status in Javascript

I've written a script that successfully generates a list of all the Lectora variables in a course and creates a button to allow the me to edit the value. Now, I want to do something similar to be able to set the Tracking Status of a page, similar to the Action "Set Tracking Status". I'm sure there's a way to access these, as well as other built-in variables that I'm not aware of, right?

Discussion (1)

This works for me:


const currentPageId = VarCurrentPageID.getValue();

trivPageTracking.SetRangeStatus(currentPageId,2);


I'd love to get my hands on your script that generates all the Lectora variables and allows for editing them.