Displaying Empty Variables (or not)

I am using my company’s UR10e in tandem with an optical sensor for some inspection operations, and we’ve identified a frustration with the displaying (or not displaying) of the actual value of variables, when those variables are cleared at some point in the program.

Context
For our purposes, we have a list called “Active_Rej” generated at program start, using a Make.List() and set as empty to start. During the program, when inspection points fail, that list is populated with the ID number of the failures, giving the operator a way to see the results as they occur.

There are also a number of other lists generated at the start, also empty, which are later used to permanently store the rejection information for each part. Since all of these lists start empty, they do not appear on the run screen with the other variables, which is actually preferred…until later on.

Issue
After each part is accepted or rejected, we want to clear the “Active_Rej” and refresh it for a new part. We perform a .Clear() on the list and re-populate it with new rejections. This works fine on the program side, but does not work so well for us on the display side. What I’ve discovered is that a variable currently displayed on the run-screen, with a value, if cleared the variable will be reset but will continue to display the prior value on the run-screen.

My assumption is the software sees that it is empty and knows it doesn’t display empty variables, so does not update the display. However, this variable was already on the display, so that leaves us with the old value still displaying until it’s given something new. Issue for us is that if the part is passing inspection, it doesn’t have anything to give to the list. Meanwhile, the operator is watching and thinking the part will be rejected. To work around that, I have to first repopulate the list with a [0] then separately clear it, so the operator only sees a 0 instead of a list of prior rejections.