AcadDoc.lsp

Discussion in 'AutoCAD' started by Sandra Rivera, Sep 29, 2004.

  1. Can anyone tell me under what circumstances Autocad will NOT load the
    AcadDoc.lsp file automatically when a new drawing is opened? The file is in
    the directory where the drawing is. After the drawing opens I can type
    (load "ACADDOC.LSP") and it loads as it should.
     
    Sandra Rivera, Sep 29, 2004
    #1
  2. Sandra Rivera

    fengk Guest

    my understanding is you won't need to use "load" to load acaddoc.lsp. It should be automatically loaded. are you just using vanilla autocad?
     
    fengk, Sep 29, 2004
    #2
  3. Sandra Rivera

    T.Willey Guest

    I think so also, but the file "acaddoc.lsp" has to be in a acad search path.

    Tim
     
    T.Willey, Sep 29, 2004
    #3
  4. Sandra Rivera

    dblaha Guest

    Actually, having the acaddoc.lsp in the same folder as the file will work wether or not that folder is defined in the acad search path. In fact, it will override any other acaddoc.lsp in AutoCAD's search path when a file in that folder is opened since the "current" folder is always the first place AutoCAD looks in it's search process. Personally, I always have the acaddoc.lsp in a specific network location for all my users. But perhaps Sandra has a specific reason for needing to have it in the same folder as the drawing?


    Dave
     
    dblaha, Sep 29, 2004
    #4
  5. Sandra Rivera

    SpeedCAD Guest

    Hi...

    Use the acad2000doc.lsp file
     
    SpeedCAD, Sep 29, 2004
    #5
  6. Sandra Rivera

    Tom Smith Guest

    No! Bad practice, highly unadvisable. That's their file. Put your stuff in
    your file.
     
    Tom Smith, Sep 29, 2004
    #6
  7. Thank you for the workaround. I copied the AcadDoc2004.lsp as is into the
    directory where it needed to be and added my load function for the
    AcadDoc.lsp at the bottom. That way these particular programs will load
    only when a drawing in that directory is opened.

    I am still curious as to why Autocad doesn't do what it is documented that
    it will do.
     
    Sandra Rivera, Sep 29, 2004
    #7
  8. Sandra Rivera

    SpeedCAD Guest

    Hi...

    What do you want do????. Do you talk spanish???. Me yes :D...

    No entiendo lo que deseas hacer.

    Un saludo de SpeedCAD... :D
    CHILE
    FORO: http:///www.hispacad.com/foro
     
    SpeedCAD, Sep 29, 2004
    #8
  9. Sandra Rivera

    Tom Smith Guest

    I am still curious as to why Autocad doesn't do what it is documented that
    it will do.

    It should. I can't reproduce that behavior. If an acaddoc.lsp exists in the
    drawing folder, it alway loads for me, and supercedes any other acaddoc.lsp,
    because the drawing folder is always first on the search path. So as far as
    I can tell, Acad 2004 and prior versions do exactly what they're supposed to
    do.

    I suspect that something else is broken, or getting in the way. Hacking the
    acad2004doc.lsp isn't the best workaround, and I'd advise finding a
    different way to do things if possible.
     
    Tom Smith, Sep 29, 2004
    #9
  10. The file should be loading automatically. It is not.
    Typing (findfile "acaddoc.lsp") returns the correct path and filename.
    Typing (load "acaddoc.lsp") with no pathname works. I get the prompts
    showing that the program is loading as it should.
    Autocad loads the Acaddoc2004 file even after it is copied to the drawing
    directory. That file is unchanged except for the (load "acaddoc.lsp") at
    the bottom. As in the warnings, I hate to do that but is there another
    alternative?
     
    Sandra Rivera, Sep 29, 2004
    #10
  11. Thank you, you have been a big help.
     
    Sandra Rivera, Sep 29, 2004
    #11
  12. Sandra,

    Been sort of following this with some interest and hoping for a logical
    solution. But anyway I have one theory to try. What is your
    REMEMBERFOLDERS system variable set to? If it is set to 1 then try setting
    it to 0 and test the behavior of your setup again if you can... but without
    Luis' code in it. The Help files provide this information on the
    REMEMBERFOLDERS variable (from AutoCAD Building Systems 2005).

    Type: Integer
    Saved in: Registry
    Initial value: 1

    Controls the default path for the Look In or Save In option in standard file
    selection dialog boxes.


    0 Restores the behavior of AutoCAD 2000 and previous releases. When you
    start AutoCAD by double-clicking an AutoCAD icon, if a Start In path is
    specified for the icon, that path is used as the default for all standard
    file selection dialog boxes.

    1 Specifies that the default path in each standard file selection dialog box
    is the last path used in that dialog box. The Start In folder specified for
    the AutoCAD icon is not used.



    So then, I can imagine that this may affect whether or not AutoCAD can find
    and load your acaddoc.lsp file. It probably also depends on what method you
    use to initialize AutoCAD and then open your files and any subsequent files.
    Sounds to me if REMEMBERFOLDERS is set to 1 and then you open a second file
    by scrolling to a different folder, which has a different acaddoc.lsp file
    in it, and opening a file (that is not in your current folder which already
    has its own acaddoc.lsp file - follow all that?) then this odd behavior
    manifests itself. There may be a situation that does not update the path
    information that the variable is affecting. I am just speculating, I don't
    know all of your settings or how you are opening files and subsequent files
    or all the situations that affect the REMEMBERFOLDERS variable. And I am
    not sure if this variable is the cause of this situation. And I did not try
    to test this theory.

    Hopefully, this will lead to an answer, let us know if you tested any of
    this please.

    Arnold Williams


     
    Arnold Williams, Oct 1, 2004
    #12
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.