LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Save data

Hi
I have an array 1-D of 20 shared variable and I want to export their value in a file in exel format as follow:
 
NAME   1th Variable                         name 2th variable               name 3th variable                ......
         14                                                     2                                                5                            ....
         15                                                     2.5                                             6                            ....
        .....
 
Someone can suggest the better way to use?
Thanks
0 Kudos
Message 1 of 13
(3,974 Views)
Just use the Write To Spreadsheet File function.
0 Kudos
Message 2 of 13
(3,959 Views)
Hi SMercurio_fc
 
Do you have any example ? thanks
 
0 Kudos
Message 3 of 13
(3,954 Views)
It's a pretty trivial function. Did you try looking at the help file?





Message Edited by smercurio_fc on 07-01-2008 10:13 AM
0 Kudos
Message 4 of 13
(3,951 Views)

My array is not of double elementes

Look the attached file

0 Kudos
Message 5 of 13
(3,945 Views)
Enzo you can always use a typecast function right?then what is the problem?
Message 6 of 13
(3,935 Views)
No, you cannot use the TypeCast function.

It seems that you are using the DSC module. When you said shared variable I assumed you were referring to "regular" shared varaibles that you create in projects. I don't have the DSC module. That said, the Get Shared Variable List VI returns an array of shared variables. You would likely need to use property nodes to get the actual values from each shared variable in the array. You will probably want to make a 2D array out of the values so  you get your table of actual values.  
Message 7 of 13
(3,921 Views)
Hi
it is right, I`m using the DSC module,
so I have to create a 2-D array?
In the property node I can`t choose the actual value for the share variable,
Can you  explain better how proceed?
thanks
 
0 Kudos
Message 8 of 13
(3,914 Views)
Well, like I said, I don't have the DSC module, so I'm only guessing here. But, you showed a table with your first post, so it seems you want a 2D array. The sample I showed for the Write to Spreadsheet File was just a sample on using the function in general. In your particular case you seem to have a list of values for each shared variable. Assuming that the number of values for each shared variable is the same you can do something like this:




Message Edited by smercurio_fc on 07-01-2008 11:35 AM
Message 9 of 13
(3,899 Views)
Hi
Each shared variable has no fixed value, I have to use a white until stop to monitor each shared variable.
So I can`t use the for loop, and also I need to read the 20 shared variable at the same time.
What I want to create is a table of 20 column, one for each shared variable and the rows are the value
of the shared variable.
 
It is clear?
thanks


Message Edited by enzo78 on 07-01-2008 12:06 PM
0 Kudos
Message 10 of 13
(3,872 Views)