LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

QD Shortcut - Chage To/From Array

Oh no - I was hoping to be able to avoid this ClassName-string CaseStructure-thing...

 

Would there be any issue with data types other than numeric in terms this reverting to a "standard representation"? For string possibly the different display styles or something?

0 Kudos
Message 11 of 24
(2,843 Views)

I put together a version of this plugin that shouldn't have any issues with the new item losing configuration. I apologize for the code messiness and lack of comments, I only had a little while to put this together.

 

It's saved in LabVIEW 2013. Place these files in your Quick Drop plugins directory. The default shortcut is Ctrl-J.

Download All
Message 12 of 24
(2,814 Views)

Nice one! Had trouble understanding the temporary CTL, but that's really smart stuff!

0 Kudos
Message 13 of 24
(2,791 Views)

Thanks. The smarts of the scripting code came from my colleague AristosQueue... I just massaged his code into a Quick Drop shortcut.

0 Kudos
Message 14 of 24
(2,770 Views)

Just found out that the new shortcut VI had trouble with Arrays existing TypeDefs. It can convert TypeDefs into an array no problem, but the reverse action gives an error 1154 when trying to replace the array with the array element from the newly created object in the temporary CTL... I inserted a case structure that passes the path of the TypeDef instead of the temporary CTL path whenever this function has to deal with an array of a TypeDef. Seems to do the trick.

 

Please find the llb with the modified subVI in question ("Execute Change To Array Or Element.vi") attached. Replace it with the existing "_ChangeToArraySupport.llb" in the "LabVIEW 201*\resource\dialog\QuickDrop\plugins" folder.

Message 15 of 24
(2,747 Views)

Thanks for discovering the issue and posting a fix, comrade.

0 Kudos
Message 16 of 24
(2,711 Views)