Block files folder

Discussion in 'AutoCAD' started by John Georgiev, Jul 19, 2004.

  1. Is it possible to start INSERT command from menu in interactive mode
    (FILEDIA=1) but to open directly in "Select Drawing File" window and in
    specific folder?
    Thank you.
    John
     
    John Georgiev, Jul 19, 2004
    #1
  2. John Georgiev

    MP Guest

    I used doslib for that

    ;default block folder
    (setq blkdir "H:\\blocks\\")

    ;;;;------user input---------
    (setq filename(dos_dwgpreview "Select block to insert" blkdir))

    not exactly what you're asking for but close enough for me.
     
    MP, Jul 19, 2004
    #2
  3. Yeah, that works, but I still prefer to find more clear solution - without
    3rd party software as DosLib. If it doesn't work - then I'll use this way.
    Thanks MP.
     
    John Georgiev, Jul 19, 2004
    #3
  4. John Georgiev

    Tom Smith Guest

    Yeah, that works, but I still prefer to find more clear solution

    You can do it with plain lisp:

    (getfiled "Select Drawing File" "h:/blocks/" "dwg" 8)
     
    Tom Smith, Jul 19, 2004
    #4
  5. Yep! This is it. I found this earlier but I tried to use path in the form
    C:\\Temp\\Folder and it didn't work. Now I tried the other form -
    C:/Temp/Folder and it worked.
    I didn't know that there is a difference between these path forms.
    Thanks guys.
    John
     
    John Georgiev, Jul 19, 2004
    #5
  6. John Georgiev

    Tom Smith Guest

    Both forms work for me just as they normally do. Note that the "default
    filename" argument must end in a delimiter to be interpreted as a path:
    either C:\\Temp\\Folder\\ or C:/Temp/Folder/.
     
    Tom Smith, Jul 19, 2004
    #6
  7. Hmmm ... I know. And I think I had it at the end.... or maybe I missed it.
    Anyway, thanks Tom.
    John
     
    John Georgiev, Jul 19, 2004
    #7
  8. John Georgiev

    ECCAD Guest

    <<C:/Temp/Folder and it worked>>
    Interesting, I think you need a "/" at the end ?
    Bob
     
    ECCAD, Jul 19, 2004
    #8
  9. Yes Bob - see the answer I gave to Tom above. I'm not sure when I tried this
    first if I missed "\\" at he end. As you see I missed it in the post, so it
    is very likely I missed it before. I didn't save the previews versions of
    the routine (I was working in the editor) and this is why I can't check what
    was the situation.
    Thanks Bob.
    Have a nice day.
    John
     
    John Georgiev, Jul 19, 2004
    #9
  10. John Georgiev

    jonesr Guest

    I use
    (command "-insert" (getfiled "Select BLOCK..." (strcat QD_GLibP "blocks/")
    "dwg" 8))
    where QD_GLibP is set to the path of my standards library)
     
    jonesr, Jul 20, 2004
    #10
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.