AutoLisp

Discussion in 'AutoCAD' started by agruno, Feb 20, 2004.

  1. agruno

    agruno Guest

    if you have acad2***

    Then
    (vl-directory-files" path" "ext" )
    if all files simpli put ext "*.*"
     
    agruno, Feb 20, 2004
    #1
  2. agruno

    naujoke Guest

    How to make a list of existing file names in specified directory?
    I dont need standard AutoCAD file dialog box (GETFILED).

    For eample there are files: data1.txt, data2.txt, ... dataN.txt in
    directory .../Data/

    How to filter files and get a list: ("data1.txt" "data2.txt" ...
    "dataN.txt")?

    Please any sugestions...
     
    naujoke, Feb 20, 2004
    #2
  3. agruno

    naujoke Guest

    Thanks "agruno"!
    It works great.
     
    naujoke, Feb 20, 2004
    #3
  4. agruno

    Jan C Guest

    Use the old MS-DOS:

    (command "shell" "dir *.txt /b >file.lst")

    This will make a file called file.lst with all txt files.
    You can open this file and read all filenames.

    Be carefull: I don't know what will happen if there are spaces in the used
    path like:

    (command "shell" "dir c:\program files\autocad 2004\support\*.pat /b
    JanC
     
    Jan C, Feb 21, 2004
    #4
Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments (here). After that, you can post your question and our members will help you out.