LabVIEW Idea Exchange

cancel
Showing results for 
Search instead for 
Did you mean: 
altenbach

Option to discard stale entries in the event queue

Status: Completed
Implemented in LV 2013

Currently problems occur with "analog" type events (value changed of a slide, cursor move, etc.) because too many intermediary events will be queued up. If the event case takes any finite amount of time to execute, we get a huge buildup of events.

 

A very illustrative example and a possible workaround can be found here. While the workaround works well for unique cases, it gets complicated quickly if event cases are shared by several controls (e.g. "graph cursor move" or "slide value changed" in the same event case).

 

What we need is an option to set the queue size of the event queue for each unique event. For example if a value change event occurs on the slide, and the same event with a slighly older value already exists in the event queue, the new event should overwrite the old event, keeping the queue at size=1 for that particular event. It should not touch queued up events of other controls, etc. of course.

 

Most likely we only need two choices: (1) infinite queue (current behavior), (2) single element queues (only the newest event of each configured event is kept in the queue). It could be implemented with a checkbox on the event configuration dialog e.g. : "[x] Discard stale events".

 

Of course if should be configurable for each unique event, not just for each event case.

 

(This idea is along the lines of Marc's idea here  and would also potentially provide a solution for Shane's xcontrol problem). 

21 Comments
wiebe@CARYA
Knight of NI

>Status changed to: Completed

>Implemented in LV 2013
 
Well, partially completed. Can't set this for user events. Have to use flush events for them...