How to create a directory with vlisp?

Gary McMaster

Usenet Archive
Joined
Jun 26, 2003
Messages
20
Reaction score
0
Hi Everyone,

I've found all kinds of file handling functions in the vlisp documentation but I don't see any directory handling functions Is it possible to check for and/or create a directory from lisp? Can anyone provide a sample of how this is done if it is possible?

Thanks in advance.

Gary
 
Thanks very much Steve.

I thought I had seen a way to handle dirs in the Acad2000 docs.

Would it be (vl-chkdir "YourFolderPath") to see if it already exists?

Gary
 
Gary,

Use (filefind), example below

(if
(not (findfile "YourFolderPath"))
(vl-mkdir "YourFolderPath")
(alert "Folder exists")
)

Steve
 
That should be use (findfile)...

Steve Jones said:
Gary,

Use (filefind), example below

(if
(not (findfile "YourFolderPath"))
(vl-mkdir "YourFolderPath")
(alert "Folder exists")
)

Steve
 
Steve,

Thanks again.

I'm familiar with findfile but never thought of using it to find a directory. Probably because I've never created a directory with lisp:)

Gary
 

Latest threads

Back
Top