Limit to number of search paths?

Discussion in 'AutoCAD' started by Jim Shipley, Nov 23, 2004.

  1. Jim Shipley

    Jim Shipley Guest

    Is there any limit to the number of search paths defined in Options > Files?
    I have about 20 there already, and am considering adding about another 10 or
    20.

    The reason is that different menus call blocks from different locations.
    The other option is to hard code the block location into the menu.

    Thanks,
    Jim
     
    Jim Shipley, Nov 23, 2004
    #1
  2. Jim Shipley

    Dommy2Hotty Guest

    I don't think there is a limit...but you gotta know when to say enough is enough. I take it your "Blocks" folder is broken down into many different sub-folders, huh? Wish AutoCAD could search subfolders too...listening AutoDesk?
     
    Dommy2Hotty, Nov 23, 2004
    #2
  3. Jim Shipley

    Jim Shipley Guest

    Exactly...

    enough. I take it your "Blocks" folder is broken down into many different
    sub-folders, huh? Wish AutoCAD could search subfolders too...listening
    AutoDesk?
     
    Jim Shipley, Nov 23, 2004
    #3
  4. Jim Shipley

    Tom Smith Guest

    I agree. I like having the blocks organized in a tree of folders, but to
    avoid having to list every folder in the search path, I use a custom
    insertion routine for blocks. If the filename isn't found on the search
    path, the routine searches a list of block folders to find it. I only put
    our lisps, custom "support" files, and custom text files on the search path.
     
    Tom Smith, Nov 23, 2004
    #4
  5. Hi,

    This type of problem can be solved fairly easily by defining a set of lisp
    variables holding the paths in a file with an MNL extension and the same
    name as the Menu file.

    In the MNL file:

    (setq Path1 "C://My First directory//")
    (setq Path2 "C://My Second directory//")

    In the MNU or MNS file

    TipKey1 [Insert block1]^C^C^CInsert;(strcat Path1 "Block1") etc as required
    TipKey2 [Insert block1]^C^C^CInsert;(strcat Path2 "Block2") etc as required

    This makes the MNS file easy to read and maintain.

    You could go further in the MNL file and define a full function which you
    call from the menu.

    eg
    (defun C:Insert1 ()
    (command "Insert" (strcat Path1 "Block1") etc to finish of the command)
    )

    The MNL file would then read:

    TipKey1 [Insert block1]^C^C^CInsert1

    with the further advantage that you can now type Insert1 at the command
    line.

    --


    Laurie Comerford
    CADApps
    www.cadapps.com.au
     
    Laurie Comerford, Nov 23, 2004
    #5
  6. Jim Shipley

    James Allen Guest

    Hi Jim,

    I haven't really looked into it yet, but I have been thinking about using
    "offline files" for this purpose. What I am thinking is to keep the
    structured directory tree on the network, but 'map' them to a single local
    directory. Then I could put the (one) local directory in the search path,
    but users could still browse the network directory structure for blocks as
    well.
     
    James Allen, Nov 24, 2004
    #6
  7. Offline files don't "map" to a single directory, unless you consider the
    hidden location of the cached files to be "mapping" the files.

    --
    R. Robert Bell


    "James Allen" <JamesA~AA~mwengrs~DD~com> wrote in message
    Hi Jim,

    I haven't really looked into it yet, but I have been thinking about using
    "offline files" for this purpose. What I am thinking is to keep the
    structured directory tree on the network, but 'map' them to a single local
    directory. Then I could put the (one) local directory in the search path,
    but users could still browse the network directory structure for blocks as
    well.
     
    R. Robert Bell, Nov 24, 2004
    #7
  8. Jim Shipley

    Jim Shipley Guest

    COOL! That worked great. Thanks a bunch.

    Had to do a bunch of find and replaces to get the insert statements reworked
    but it is a nice solution.

    Jim

     
    Jim Shipley, Nov 24, 2004
    #8
  9. Jim Shipley

    James Allen Guest

    I was afraid of that. Oh well.

    Thank You,

    James
     
    James Allen, Nov 24, 2004
    #9
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.