You would need create your own function to update your fields and then call this function from an event subscriber. You can use the Event Recorder in BC to find out which events are published and then find where the subline function is called.
Getting the event recorder to work may need a few tries. In my case I noticed the if an error occurs, then it doesn’t record anything. But if going from the event recorder page (via search) to the page with the function I want to record, then do the process (with no errors - this is NOT a debugging tool) and exits back to the event recorder page. Then when I click Stop it asks me if I want to display the events that it recorded.
In you case then at least it should record when you opened the statistics page.
But you may be in a situation where there are no usable events to subscribe to. In which case you can do two things:
1: Go to AL on Github to request the event publishers you would need. This event then (maybe) will be added to the next major release. Or request it via MS support for current versions.
2: Create a new statistics page. Copy existing functions etc. and make your own page.
Requesting the event publisher may take 6 months or more to be available but only a few hours when available, where as creating the new could be done now, but take a lot more than with a subscriber. Not ideal, but the number of events is still limited, compared to how much functionality exists in NAV/BC.
Stan, your are completely missing the point with extensions. You cannot expect to convert an existing customization to extension with the same functionality. Extensions only offer a small subset of the customization capabilities we are used to in C/Side.
Instead you will often have to examine the underlying need this customization is trying to fulfill. Then you will often have to rethink how to fulfill this (or atleast some of it) with the limited capabilities you have with extensions. If the gap is too big, then you should either convince the customer that he/she doesn’t need this customization anymore or you will have to do a lot of copy-code to your own extension objects. This approach might not cause conflicts in future upgrades, but then your copy-code won’t benefit from Microsoft updates either.