LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

data entry in array-constant

Solved!
Go to solution

Hello,

 

is there a more comfort possibility to enter a lot of values in an array constant in the block diagram? I want to built a constant with several hundred values without typing them in. For example with cut and paste?

 

Thanks,

 

Christian

 

 

Message 1 of 5
(2,721 Views)

It would really depend on what kind of dataq you are trying to generate. If you can tell us what you are trying to do with your data then we can make better suggestions.

 

Basiclly you would use a for loop and generate you data that way. See the example below:

 

24392iF45E862A5831B6C2

 

This example will generate 500 points of random data between 0 and 1.

Tim
GHSP
0 Kudos
Message 2 of 5
(2,710 Views)
Solution
Accepted by topic author cosw

If you can read the data from a file or database, you can simply load the data and output to an indicator.

 

Select the indicator on the block diagram, right click and select "Change to constant".

 

 

 

 

0 Kudos
Message 3 of 5
(2,698 Views)

This is one of my most-used Quick Drop shortcuts.  You can copy data to the clipboard and create an array in LabVIEW.

 

http://forums.ni.com/t5/LabVIEW/QD-Shortcut-Paste-to-Array-Constant/m-p/1088366#M481582

 

Before this, lots of throwaway VIs were written to read files.  You can now export to the clipboard, LV needs to close the loop and let you import as well.

0 Kudos
Message 4 of 5
(2,694 Views)
Oh thanks, that works. I have a reference table for thermocouple for linearization and in the sample VI from NI was no C-type thermocouple. Christian
0 Kudos
Message 5 of 5
(2,662 Views)