LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Modify a VI from spreadsheet or similar.

Solved!
Go to solution

Hello,

 

I am looking to modify a VI such that I can add this into a TestStand Sequence and have access to a drop-down list based on information from a spreadsheet.  A very simplistic example of what I'll be using this for, is having a spreadsheet that includes rows with unique: User Names, User IDs, User Station locations, etc.

 

I want to add this VI into a TestStand sequence and have the ability to select from a drop down list of all User Names, prior to running the TS seq.  Based on which User Name is selected I will pass along the User IDs in the background.  User Names might be the same, so that will also need to be considered, since I am using the index of the selected name to dump out other contents.

 

I know how to do this by having a VI come up during TS execution and read in from a spreadsheet, but this is not an ideal case for the implementation that I am going for.  Ideally I can programatically create the VI, but this might be tricky since I will need to either preconfigure the control/indicators/tunnelling and somehow update contents then save the VI with the new contents somehow.

 

Another, potentially easier approach might be if it is possible to somehow fill/update + save a TypeDef or Enum w/in a VI with contents from a spreadsheet.  I could just create a an enumerated list for each item like User Name, User ID, etc.

 

Any advice on this approach would be appreciated.  Thanks.

0 Kudos
Message 1 of 6
(1,707 Views)
0 Kudos
Message 2 of 6
(1,691 Views)

zou.  I appreciate the feedback.  I was only using this as a rough example, my spreadsheet will be far more complex.  I might have picked a bad example in this case, there will be no User Names/IDs in my actual implementation.

 

Thanks.

0 Kudos
Message 3 of 6
(1,665 Views)

Actually, I believe if I were able to convert a 1D array to an enum I should also be able to make this work.  I am digging into this now.  If anyone has any feedback here I would appreciate it.

0 Kudos
Message 4 of 6
(1,639 Views)
Solution
Accepted by NI_User_11108

Can't do this with an enum, use a ring instead.

 

George Zou
Message 5 of 6
(1,633 Views)

Yep, I ended up using a ring and got things working.

 

Thanks.

0 Kudos
Message 6 of 6
(1,631 Views)