LabVIEW Idea Exchange

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

Convert case structure to event structure and vice versa

Status: New

The argument is similar to what falkpl suggested here. The issue is refactoring old (pre event structure) code.

 

Many times I had the need to convert a multi-case case structure to an event structure where each event case duplicates one of the original cases. This is currently hard to do and involves a lot of copying and wire mending.

 

Of course the conversion cannot do any event assignments so things will be broken, but for me it would be sufficient to create the new event structure as a 1:1 "event-case":"plain-case" conversion of the code contents, without any events assigned. (This must be trivial in terms of code!) Assigning the events later is easy.

 

For symmetry, the reverse operation ("replace event structure with case structure") should also be available.

1 Comment
X.
Trusted Enthusiast
Trusted Enthusiast

Argh! I am stuck in the reverse situation and I have no clue how I can simply convert a "do-it-all" event structure into a Action Engine Case structure (the event structure will be put in a separate loop with a queue to send instructions to the Action Engine).

I am resorting to dragging my event structure out of the loop, replace it with a Case Structure connected to the enum I am using as my action list and repopulating each case with the content of the corresponding Event Structure case.

Insane.