LabVIEW

cancel
Showing results forย 
Search instead forย 
Did you mean:ย 

Save a file in a very particular path - help needed

Hello, i have to save a file in a particular directory.

well, i have 3 subdirectory ๐Ÿ™‚

the main directory correspond to the year when i made a test (it must be "0" for 1990, 2000 is "A" and so on.)
the subdirectory is the month (january is "1"---> December is "C")
the one another directory is the day from 1 to X (for the 31th day)

each time i run my program i have to control if the folder(s) exist, if it/they doesn't/don't exist i have to create it/them.

and save my file into the correct folder obviusly.

Some idea? ๐Ÿ™‚

Using LabVIEW 7.1
0 Kudos
Message 1 of 39
(3,769 Views)

Try the attached. Note that as you stated your year and month to be in hex, I also made the day in hex. You need to give this program the path where the year folders should be, the name of the file you wish to save and the string text that you want saved. It will then create your desired folder structure based on the current timestamp and save the data to a text file.

Charles Chickering
Architecture is art with rules.

...and the rules are more like guidelines
0 Kudos
Message 2 of 39
(3,754 Views)

I forgot that you said you are in LabVIEW 7.1. Unfortunately I can only save back to LabVIEW 8 so I have attached an image of my block diagram with the functions labeled. Hopefully this will suffice to get you what you need.

Charles Chickering
Architecture is art with rules.

...and the rules are more like guidelines
0 Kudos
Message 3 of 39
(3,751 Views)

OpenG has a really good Create Dir if Non-Existant VI.  Try to give it a look.



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
0 Kudos
Message 4 of 39
(3,743 Views)

I am in the same boat as Charles, so its in version 8.0.You can post it in the version conversion board and get it converted.

From what I understand, you dont mean hex but after 9 you want to start from A. Here is my version but in 8.0!


CLA CTAChampionI'm attending the GLA Summit!
Subscribe to the Test Automation user group: UK Test Automation Group
Download All
0 Kudos
Message 5 of 39
(3,740 Views)

I really wish NI would push the OpenG lib directly into LabVIEW. I hesitate to suggest solutions with it here in this forums as most newcomers don't want to fiddle with VIPM and installing additional packages.

Charles Chickering
Architecture is art with rules.

...and the rules are more like guidelines
0 Kudos
Message 6 of 39
(3,735 Views)

Well, I should also point out that you only need to create a folder once (the lowest folder).  The Create Folder function will create the entire directory structure needed to make a folder.  I tested this with 8.2.1.  Not totally sure if it works the same with 7.1.



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
0 Kudos
Message 7 of 39
(3,726 Views)

i can't use openG library ๐Ÿ˜ž 

 

and it's correct...it's not a hex code, it's similar but it's different...hex is max F, my needs is go also after the F

 

@aCe i put your vi's in convert forum...i'm waiting for a reply

Using LabVIEW 7.1
0 Kudos
Message 8 of 39
(3,698 Views)

Why can't you use the openG library? It seems it would solve your problem.

 

-CC

----------------------------------------------------------------------------------------------------------------------------
"If anyone needs me, I'll be in the Angry Dome!"


0 Kudos
Message 9 of 39
(3,658 Views)

.aCe in version conversion told me that one subVI is missing ๐Ÿ˜ž

Using LabVIEW 7.1
0 Kudos
Message 10 of 39
(3,621 Views)