chelsea1307 Posted August 18, 2009 Posted August 18, 2009 I have 5 dwgs that need the same xrefs attached is there a script that could do this Needs A-FP01-296000100.dwg A-FP01-basea-296000100.dwg A-FP01-baseb-296000100.dwg attached in model space and G-TBE-VR-.dwg attached in paper space I tried to write a script once and couldnt get past the open part im gonna start trying for this one but help would be great Quote
chelsea1307 Posted August 18, 2009 Author Posted August 18, 2009 i think this will do the xreffing but im stuck on the opening of dwgs tilemode 1 -xr a A-FP01-296000100.dwg 0,0,0 1 1 0 -xr a A-FP01-basea-296000100.dwg 0,0,0 1 1 0 -xr a A-FP01-baseb-296000100.dwg 0,0,0 1 1 0 tilemode 0 -xr a G-TBE-VR-.dwg 0,0,0 1 1 0 Quote
alanjt Posted August 18, 2009 Posted August 18, 2009 I have 5 dwgs that need the same xrefs attached is there a script that could do thisNeeds A-FP01-296000100.dwg A-FP01-basea-296000100.dwg A-FP01-baseb-296000100.dwg attached in model space and G-TBE-VR-.dwg attached in paper space I tried to write a script once and couldnt get past the open part im gonna start trying for this one but help would be great download a copy of ScriptPro, it's an autodesk released product (no longer updated), but still on their website. it will allow you to select as many drawings as you like, select a .scr file and it will process everything for you. the other nice thing about .scr files is, you can just load some lsp code and it will process it just the same. once in a while, i still run scriptpro to batch several drawings. save this as a .scr file and have scriptpro run it on the drawings you wish to edit: (foreach x (list "A-FP01-296000100.dwg" "A-FP01-basea-296000100.dwg" "A-FP01-baseb-296000100.dwg" "G-TBE-VR-.dwg" ) ;_ list (cond ((wcmatch x "A-*") (setvar "tilemode" 1)) ((wcmatch x "G-*") (setvar "tilemode" 0)) ) ;_ cond (and (findfile x) (command "_.-xref" "_attach" x '(0 0 0) 1 1 0) ) ;_ and ) ;_ foreach (command "_.qsave") what about the layer? right now they will just placed on the current layer. found it, here's the link: http://usa.autodesk.com/adsk/servlet/item?siteID=123112&id=4091678&linkID=9240618 Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.