LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

how to save daq data-in(from 2 channels) in 2-D arrey?

Solved!
Go to solution
It's a little unclear what you need. If you have two scalars, you can use the Build Array function to create a 1D array and with another Build Array, append to an existing 2D array using a shift register. If you just want to append new values to a file, the Write to Spreadsheet function does have a 1D input.
Message 11 of 34
(653 Views)

@Dennis_Knutson wrote:
It's a little unclear what you need. If you have two scalars, you can use the Build Array function to create a 1D array and with another Build Array, append to an existing 2D array using a shift register. If you just want to append new values to a file, the Write to Spreadsheet function does have a 1D input.

I have 2 Analog information(voltage and angle) from Analog system to my DAQ card. i want to save this  informations in excel in 2 columns. column1: angle and column2: the voltage of that angle). thats all wich i want to do.

 

0 Kudos
Message 12 of 34
(643 Views)

@Eram wrote:

@Dennis_Knutson wrote:
It's a little unclear what you need. If you have two scalars, you can use the Build Array function to create a 1D array and with another Build Array, append to an existing 2D array using a shift register. If you just want to append new values to a file, the Write to Spreadsheet function does have a 1D input.

I have 2 Analog information(voltage and angle) from Analog system to my DAQ card. i want to save this  informations in excel in 2 columns. column1: angle and column2: the voltage of that angle). thats all wich i want to do.

 


What is wrong with using the Write Spreadsheet file?  Show us your code so we can see where you are stuck.


GCentral
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
Message 13 of 34
(639 Views)

I don't have access to DAQ card now,so for example i choose 2 parameter (x and x^2).i'm going to change x manually and save x and X^2  in a excel file.and draw the chart. but i can't do it as easy as it seems to be ! i don't know what's the problem?  this vi is  attached .

thanks a lot...

0 Kudos
Message 14 of 34
(634 Views)

I have problem when i want to enter data save-path   in file spreadsheet  ! i don't now what is destination file format?

0 Kudos
Message 15 of 34
(627 Views)

The Write To Spreadsheet File saves the data in a delimited text file.  By default, the delimiter is a tab.


GCentral
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
Message 16 of 34
(625 Views)

@crossrulz wrote:

The Write To Spreadsheet File saves the data in a delimited text file.  By default, the delimiter is a tab.


thanx a lot . now i can see one result in txt format file.

but when i press Run button it wants a destination.i choose any destination even file.txt .but it wants another destination imediately and in every text file there is just 2 data (x and X^2). i mean i don't have series of data during changing the input number. the file is attached below...

thanks for your quick and useful responses...

0 Kudos
Message 17 of 34
(616 Views)
Please turn on Context Help and read about Write to Spreadsheet File.

To avoid the file path dialog, use a front panel control outside your main loop or a shift register to pass the path from the first iteration to successive ones.

You have to tell the function to append as noted in the help.
Message 18 of 34
(612 Views)

@Dennis_Knutson wrote:
Please turn on Context Help and read about Write to Spreadsheet File.

To avoid the file path dialog, use a front panel control outside your main loop or a shift register to pass the path from the first iteration to successive ones.

You have to tell the function to append as noted in the help.

I read about spredsheet,but i don't understand it . there is something about active X and,... . .But i became a little confused!!

how can i use shift register? do shift register let me to have all data in a page?

thanks

0 Kudos
Message 19 of 34
(595 Views)
There is nothing related to ActiveX with the Write to Spreadsheet File.

If you do not provide a path with a front panel control or the file dialog function outside a loop, you will be prompted for a file path when the function is called. The function outputs this file and with a shift register containing the path, the next time the function is called inside the loop, the previously selected path will be used and you will not be prompted.

So, you can use a front panel path control, the file path dialog, or a shift register.
Message 20 of 34
(587 Views)