vl-directory-files (파일 이나 폴더이름 가져오기)
Auto CAD/lisp2018. 12. 2. 19:08
vl-directory-files (AutoLISP)
Lists all files in a given directory
Supported Platforms: Windows and Mac OS
Signature
(vl-directory-files [directory pattern directories])
- directory
Type: String
Directory name to collect files for; if nil or absent, vl-directory-files uses the current directory.
- pattern
Type: String
Valid wildcard pattern for the file name; if nil or absent, vl-directory-files assumes “*.*”
- directories
Type: Integer
Value that indicates whether the returned list should include directory names. Specify one of the following:
-1 -- List directories only
0 -- List files and directories (the default)
1 -- List files only
Return Values
Type: List or nil
A list of file and path names; otherwise nil if no files match the specified pattern.
Examples
- Windows
(vl-directory-files "c:/acadwin" "acad*.exe") ("ACAD.EXE" "ACADAPP.EXE" "ACADL.EXE" "ACADPS.EXE") (vl-directory-files "e:/acadwin" nil -1) ("." ".." "SUPPORT" "SAMPLE" "ADS" "FONTS" "IGESFONT" "SOURCE" "ASE") (vl-directory-files "E:/acad" nil -1) ("." ".." "WIN" "COM" "DOS")
- Mac OS
(vl-directory-files "/myutilities/lsp" "*.lsp") ("utilities.lsp" "blk-insert.lsp") (vl-directory-files "/myutilities" nil -1) ("." ".." ".DS_Store" "Help" "Lsp" "Support")
'Auto CAD > lisp' 카테고리의 다른 글
폭파하지 못하는 블록을 폭파 가능하게 만드는 리습 (0) | 2018.12.27 |
---|---|
Visual LISP and Layers (0) | 2018.12.18 |
vlisp-compile (AutoLISP/Visual LISP IDE) (0) | 2018.12.01 |
vlr-lisp-reactor (리액터) (0) | 2018.11.30 |
Vlax-Curve (0) | 2018.11.30 |
댓글()