07-18-2013 04:43 PM
Hi 🙂
I'm writing to a text document and I want to name the file by the first word in the document. Can File Dialog automatically name a file by its first word?
Thanks a lot.
07-18-2013 05:47 PM
I'm pretty sure the File Dialog has a default name input (don't exactly have LabVIEW in front of me right now). Even still, if you are naming the file, do you really want the user to see a dialog? Just build up the file path programatically.
07-19-2013 02:01 AM
@msuraz27 wrote:
I'm writing to a text document and I want to name the file by the first word in the document. Can File Dialog automatically name a file by its first word?
It can be done, but 'File Dialog' cannot do it at its own, rather you need to provide 'default name' input to the 'File Dialog' express VI.
07-19-2013 04:30 PM
The "direct" way to do this is to use Open/Create/Replace File (from the File I/O Palette) and wire in the path you want to use for the file name. Note you'll probably build this path using (naturally) Build Path, with the Base Path being the folder (or device) you want to use, and the Name being a string obtained from the first word of the document you are trying to save (possibly with an extension, e.g. .txt, concatenated to it).
BS