+ Reply to Thread
Results 1 to 5 of 5
  1. #1
    Junior Member
    Using
    AutoCAD 2013
    Join Date
    Feb 2013
    Posts
    10

    Default Trying to Automatically update/redefine block in Thousands of drawings

    Registered forum members do not see this ad.

    Good evening.
    I'm hoping that someone here can come through for me with some programming assistance.

    I currently need to update a gennote block numerous drawings in tons of different folders under one drive (F:\ drive).

    I would like to get a routine that would start in the F Drive and Automatically go to each subfolder, open each drawing, insert 'gennotes=', erase "last", save the drawing, exit out, and go to the next drawing and do the same.

    Then move on to the next folder and repeat the process until it makes it through all the folders and dwg files.

    I started with a batch file that I cannot seem to get to work:

    FOR /r %%f in (F:\*\*.dwg) DO START /WAIT
    C:\"2012"\"Autocad 2012 - English"\acad.exe "%%f" /b
    F:\scripts\gennotesupdate.scr

    Gennotesupdate script:

    Insert
    gennotes=z:\blocks\gennotes
    0,0 1 1 0

    Erase L

    Save
    Y

    ____
    That is all I have and Autocad opens but says it cannot find the specified files. I hit OK and autocad remains open. Nothing else happens.

    If there's a better way to accomplish my task I would appreciate the assistance. Or if this is the best way, any tweaking to make this work would be appreciated.

    Thanks,

    John W.

  2. #2
    Luminous Being Dadgad's Avatar
    Using
    AutoCAD 2013
    Join Date
    Nov 2011
    Location
    At the confluence of worthlessness & invaluability
    Posts
    6,051

    Default

    Welcome to CADTutor.

    Check out this lisp from Lee Mac
    http://www.lee-mac.com/scriptwriter.html

    it is but one of a great many which Lee very generously makes available for free
    on his site. Thanks Lee!
    If this doesn't do it for you, check his other lisps for one that may.
    Volume and repetition do not validate opinions forged in the absence of thought.

  3. #3
    Junior Member
    Using
    AutoCAD 2013
    Join Date
    Feb 2013
    Posts
    10

    Default Can't open link

    Thanks Dadgad but the Google says the link below is invalid and cannot locate.

    Quote Originally Posted by Dadgad View Post
    Welcome to CADTutor.

    Check out this lisp from Lee Mac
    http://www.lee-mac.com/scriptwriter.html

    it is but one of a great many which Lee very generously makes available for free
    on his site. Thanks Lee!
    If this doesn't do it for you, check his other lisps for one that may.

  4. #4
    Luminous Being Dadgad's Avatar
    Using
    AutoCAD 2013
    Join Date
    Nov 2011
    Location
    At the confluence of worthlessness & invaluability
    Posts
    6,051

    Default

    You don't need to Google it, it is an active link in the forum post,
    just left click on it, and it will take you right there to Lee's lisp and his site.
    Volume and repetition do not validate opinions forged in the absence of thought.

  5. #5
    Full Member
    Computer Details
    JGA's Computer Details
    Operating System:
    Win7
    Using
    AutoCAD 2014
    Join Date
    Jul 2007
    Location
    Scotland
    Posts
    77

    Default

    Registered forum members do not see this ad.

    I would use AutoDesk ScriptPro which would get around using batch files - just search for all the dwgs you want & drag 'n drop them onto the scriptpro pane. Also, the ACAD console would run quicker, as it doesn't load the user interface. A very good entry on the topic is found at...
    http://www.cadtutor.net/forum/showth...692#post519692

    I would try adding a .dwg to the end of the drawing/block you want to insert, you could also add "" around the path.

Similar Threads

  1. Update title block attributes in multiple drawings
    By t357 in forum AutoLISP, Visual LISP & DCL
    Replies: 142
    Last Post: 12th Dec 2016, 09:38 am
  2. Command to redefine/update mulitple wblock?
    By Benjo in forum AutoCAD 2D Drafting, Object Properties & Interface
    Replies: 5
    Last Post: 11th Jun 2012, 08:58 pm
  3. Replies: 9
    Last Post: 14th Oct 2011, 01:52 pm
  4. Automatically Update Title block lisp HELP!
    By Millsy29 in forum AutoLISP, Visual LISP & DCL
    Replies: 5
    Last Post: 15th Jul 2010, 05:29 pm
  5. Redefine block in 400+ drawings
    By MiGo in forum AutoLISP, Visual LISP & DCL
    Replies: 11
    Last Post: 16th Feb 2010, 10:17 pm

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts