LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

connect 1d array of strings to an input string terminal

Solved!
Go to solution

I am trying to connect 1D array of strings output to a strings input but it will no let me.

0 Kudos
Message 1 of 40
(5,994 Views)
Solution
Accepted by topic author reggie2016

An array of strings and a string are very different things. Your arrays seem to contain only a single element, so insert an "index array" to get that element as a plain string.

 

Where do these string array diagram constants come from? If it is just a diagram constant, grab the element and move it out of the array container, then delete the array container.

0 Kudos
Message 2 of 40
(5,986 Views)

From what to what are you trying to connect?  There are way too many possibilities in the example you gave us.



There are only two ways to tell somebody thanks: Kudos and Marked Solutions
Unofficial Forum Rules and Guidelines
"Not that we are sufficient in ourselves to claim anything as coming from us, but our sufficiency is from God" - 2 Corinthians 3:5
0 Kudos
Message 3 of 40
(5,981 Views)

And what exactly are you trying to do here?  There is no need to open a file 3 times in parallel.  Just open it once and do whatever reads you have to with the same reference, preferable in series.  You might even be able to just use a FOR loop to do all of your reads.



There are only two ways to tell somebody thanks: Kudos and Marked Solutions
Unofficial Forum Rules and Guidelines
"Not that we are sufficient in ourselves to claim anything as coming from us, but our sufficiency is from God" - 2 Corinthians 3:5
0 Kudos
Message 4 of 40
(5,972 Views)

I just added an index array and it works good now.

0 Kudos
Message 5 of 40
(5,969 Views)

im not that good at labview quite yet to put it in for loops and stuff like that.

0 Kudos
Message 6 of 40
(5,966 Views)

what i am trying to do is read the data collected from my daq modules and display them on three different graphs.

0 Kudos
Message 7 of 40
(5,963 Views)

If you are new to LabVIEW here are some tutorials when you get some time.

 

NI Learning Center

NI Getting Started

-Hardware Basics

-LabVEW Basics

-DAQ Application Tutorials

 

3 Hour LabVIEW Introduction

6 Hour LabVIEW Introduction
Self Paced training for students
Self Paced training beginner to advanced, SSP Required
LabVIEW Wiki on Training

 

As for you issue specifically.  An understanding of what the data represents is important, and knowing this will likely answer your question for you.

 

Lets say you have a single analog reading of 5 volts.  This is a scalar double.  Now you want to graph it so you grab the Waveform Graph and put it on the front panel.  But when you wire your 5V reading to the graph it says you need to provide a 1D array.  This makes sense when you realize the graph is intended to display many values at once, not just one value.  This is why it wants an array of values to put on the graph all at once.

 

A single reading can be turned into an array using the Build Array function, but it is still just a single reading.  If you wired your 5V reading to a build array then to the graph it would run, but what would you see?  Nothing because the graph can't display a single point of data, it needs multiple values.  So you could try to build previous 5V readings into the array so you have multiple values to display at once.

 

Your situation is similar, you need to understand why you have a 1D array of strings, and you need to understand why your function needs a single string value.  

0 Kudos
Message 8 of 40
(5,939 Views)

Here's how you would use a FOR loop. No duplicate code! 😉

 

 

Download All
0 Kudos
Message 9 of 40
(5,937 Views)

you make this look super easy.

0 Kudos
Message 10 of 40
(5,930 Views)