LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

error 7 creating a file

Solved!
Go to solution

Hi 

 

I think I am missing some thing simple but cant work it out! 

 

I am trying to create a file. I have simply wired a path to a file that doesnt exist yet in to a open/create/replace file vi and it keeps giving me error 7 even though I have told it to create the file. Any suggestions? 

 

Labvie 11.0.1f2 (32bit)

0 Kudos
Message 1 of 3
(649 Views)
Solution
Accepted by topic author shavecp

Solved

 

You need to make sure all the folders in the path are created first! 

 

0 Kudos
Message 2 of 3
(647 Views)

@shavecp wrote:

Solved

 

You need to make sure all the folders in the path are created first! 

 


In these cases I generally use the OpenG function "Create Dir If Non-Exist" which will make folders recursivly if they don't exist.  So if I want to make C:\blah\test\what and there doesn't even exist a C:\blah, then that function will make all of the folders needed.  If the folders already exist it does nothing.

Message 3 of 3
(603 Views)