04-01-2017 01:55 PM
so u suggest that i wire my data in the "array port of the array to spreadsheet" command and then do the rest?? open/create file, write to file and close???
04-01-2017 02:04 PM
@chris_kal wrote:
so u suggest that i wire my data in the "array port of the array to spreadsheet" command and then do the rest?? open/create file, write to file and close???
Yes.
(... except for the word "then", which implies an execution order. You can open/create the file before, in parallel, or after you do the "array to spreadsheet string" thing. The rest will fall into place as long as you use data dependencies. Only close after you write the header and the data)
04-03-2017 03:49 AM - edited 04-03-2017 03:49 AM
I also found that, but when I am putting it inside my while loop it doesn't work. I couldn't make it with ur way altenbach. Do u also know how to have a column with time in front of all my values?? like:
1,000
2,000
3,000
4,000
.
.
.
04-03-2017 04:56 AM
i found it 🙂 thaaaaanks a lot 🙂 🙂 🙂 🙂 thanks RTSLVU and all of you for answering 🙂
CHRIS
04-03-2017 09:23 AM - edited 04-03-2017 09:30 AM
@altenbach wrote:
@RTSLVU wrote:
Inside it just formats the time stamp and does this:
Can you explain the reason to use a format of %S here? I don't get it.
I am using the "Write Text File vi so I need strings...
%S simply converts the numeric to a string without changing the number in anyway. Way back when I first started programming in LabVIEW 5.1 this was the only way I could figure out how to avoid the rounding that using %f appeared to be causing. LIke so many things these days I probably don't need to do that anymore, just like the timestamp formatting the that VI also does.
@altenbach wrote:
@RTSLVU wrote:
Here is an example of steps 1 and 2
I would strongly suggest to replace the above code with "array to spreadsheet string", using an array of header strings (which you often already have) as input. The default delimiter will give you the identical result, including the termination.
Yes I know, but I find this while looking more cumbersome easier to edit. Moving from cell to cell in an array is a pain in the ass.
Now just do a little sub-vi like this to format the headers...
This allows me to quickly change, add, or, remove headers by editing one line of text.
04-04-2018 09:52 AM - edited 04-04-2018 09:53 AM
Please, can someone give me a print or VI file of the solution in a older version? I work in a computer that has NI LabVIEW 2014, so I can't open the solution (which is in 2016 version).
Thanks for the attention!
04-04-2018 10:24 AM
@ThiagoKuerten wrote:
Please, can someone give me a print or VI file of the solution in a older version?
To get a "print", you can print the above image. To get a VI, just recreate the code. It is simple enough and should not look any different in 2014. Is there any part you don't recognize?
04-04-2018 01:14 PM
Yes, I'm working with LabVIEW a short time ago, and now it's my first experience with measurement file's creation. So I would like to get a VI to see and learn about each diagram blocks that I need to use.
04-23-2019 05:12 PM
Hi RTSLVU,
Could I trouble you for some dumbing-down of your excellent File I/O explanation for my benefit?
The code snippet I wrote in WTMFile.png works well to acquire and save the required data.
Great, except, I still do not understand how to change the column headers from Untitled, Untitled 1, etc., to a meaningful names i.e. PSU Monitor, Temp Monitor.
I really like the first-principles way you suggest of ditching the Express VI and using low-level File I/O commands, however, I got stuck on Step 3.
So, might you be inclined to describe how to write headers through the Express VI or elaborate a bit more on your method?
I've hit a wall using the Write To Measurement File Express VI, with respect to how segment headers are handled, as most of the web "advice" just regurgitates the NI help file information and I haven't been able to integrate the Forum solutions on this subject.
Thanks for any time you might have to help.
04-23-2019 05:27 PM - edited 04-23-2019 05:29 PM
Well as I said lose the Express VI, although I am pretty sure you can set the headers in the Express VI. But I don't know how to do that as I have been using LabVIEW before the inception of Express VI's and never found the need for them. Frankly to me Express VI's are not intended for "production" use they are only there for those 2 hour LabVIEW sales pitches seminars to show managers how fast you can just throw something together in LabVIEW.
This is what your program should be doing