LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Index array to string doesn't work

Hello,

 

With the attached file, I'm probably stupid but i've got this problem.

 

the vi "selection des voies" select the name of the device channels

The vi " selection colonnes" display the name of the channel and select the colum for excel writing

 

so, the vi can't display into the string the name of the selected channel

I'm cetainly doing something wrong, but i don't see where

please help me

 

thank you for your help

0 Kudos
Message 1 of 4
(3,184 Views)

Hi 968012,

Your attached folder has too many VIs which VI, in particular, which you are referring to? The one you specified is not in the folder, it will be easier to list the VI that you need the community help with.....

0 Kudos
Message 2 of 4
(3,148 Views)

In the main vi you have a link betwen vi;

selection des voies.vi 

and selection colonne.vi

 

a string array called; liste mesure selectionné  is set in the selection des voies.vi  and read into selection colonne.vi

 

I called the array and index it to write string indicators

but it doesn't work

0 Kudos
Message 3 of 4
(3,135 Views)

Hi number,

 

maybe it would help NOT to ReInit "all values to default" in your "selection colonne" BEFORE reading that control named "array"…

(Homer would say "Doh!")

 

On those VIs:

  • All your VIs should have applied some Autocleanup.
  • As far as I looked at those VIs you use WAY TO MUCH local variables: use more wires AND use the unused terminals!
  • Using sequences is showing you don't THINK DATAFLOW as is described in the first chapter of the LabVIEW help (on "LabVIEW basics")!
  • Many VIs aren't properly included in your project, they only appear in the dependencies.
  • You really should use clusters (and array of cluster), like in this "selection colonnes", to greatly simplify your VI block diagram…
  • You can resize IndexArray, no need for 20 instances! (Again: using arrays of cluster with autoindexing loops would greatly simplify your block diagram!) (in "selection colonnes"…)
  • Why do you need to open/close the frontpanel of subVIs using properties/methods? Why not simply change the VI window properties to "Open on call" and "Close afterwards"???
  • Why don't you use a radiobutton in your "selection essais"? No need for additional boolean logic! (Use some wait inside that CPU-burning loop!)
  • Much more…

Example for "selection colonnes":

check.png

No unneeded locals, no sequence frames, much less block diagram…

You can hide the index of the cluster arrays, and paint all array/cluster borders transparent to get the very same look as before!

 

Found this in your VI:

check.png

If they are really involved in creating that monster I would not recommend them for further LabVIEW-related projects…

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 4 of 4
(3,110 Views)