Announcements

Announcement: We’re aware of an issue affecting starting a new topic from category pages and creating new blog posts. New topics can still be started directly from the relevant board. Learn more here.

Can I open multiple drawings by only opening one?

Can I open multiple drawings by only opening one?

zachlampert
Participant Participant
1,554 Views
5 Replies
Message 1 of 6

Can I open multiple drawings by only opening one?

zachlampert
Participant
Participant

So I have a surface dwg that needs updated everytime I update the corridor dwg. What I would like to do is have my surface dwg open automatically anytime the corridor dwg is opened. Is that possible? I am thinking possibly using a different template? 

0 Likes
1,555 Views
5 Replies
Replies (5)
Message 2 of 6

MMcCall402
Mentor
Mentor

You can open more than one file at a time by holding the Crtl key while selecting the file(s) in the open file selection window.

 

File, Open, select the corridor dwg, hold the Ctrl key, select the surface dwg, Open

 

 

Use Shift to select a range of files to open

Mark Mccall 
CAD Mangler


EESignature


VHB - Engineering, Inc.

0 Likes
Message 3 of 6

zachlampert
Participant
Participant

Thanks MMcCall402, I'm aware of how file explorer operates. What I'm trying to figure out is can I make AutoCAD open more than one drawing by only opening one? Can I let Civil3D know to open the surface drawing automatically whenever the corridor dwg is opened? Can I link the two, perhaps as a dwg template or some other process?

0 Likes
Message 4 of 6

MMcCall402
Mentor
Mentor

I know of nothing that would do it automatically.  You can open multiples thru the sheet set manager but you still have to select more than one just like the file manager.

Mark Mccall 
CAD Mangler


EESignature


VHB - Engineering, Inc.

Message 5 of 6

Ranjit_Singh
Advisor
Advisor

Hi @zachlampert. Type below at your command prompt to get the acaddoc file location

(findfile "acaddoc.lsp")

Browse to that file through windows explorer; open the file and add below code at end of that file 

(defun-q MYSTARTUP ( )
(if (= "G:\\2017\\Drawing-1.dwg" (strcat (getvar 'dwgprefix) (getvar 'dwgname))) (vla-add (vla-get-documents (vlax-get-acad-object)) "G:\\2017\\Ref\\Drawing-2.dwg")))
(setq S::STARTUP (append S::STARTUP MYSTARTUP))

Save and close the acaddoc file and you should be done.

Note that above code uses Drawing-1 and Drawing-2 as examples; replace them with true paths for your files. The files do not need to be in same location or even same drive, as long as you pass the complete paths. Also do not simply copy file paths as shown in windows explorer; the slash "\" is passed as double slash "\\" in lisp. Basically the code is structured to open Drawing-2.dwg automatically once you open Drawing-1.dwg

If (findfile "acaddoc.lsp") returns nil then simply create a new acaddoc.lsp (it's a text file with lsp extension) and put it in one of the support paths. For example, it is located here on my machine

Command: (findfile "acaddoc.lsp")
"C:\\Users\\myusername\\appdata\\roaming\\autodesk\\c3d 2015\\enu\\support\\acaddoc.lsp"

 

0 Likes
Message 6 of 6

Joe-Bouza
Mentor
Mentor
A script will do this. Assign it to a button to ope "corridor"

Joe Bouza
Did you find this post helpful? Feel free to Like this post.
Did your question get successfully answered? Then click on the ACCEPT SOLUTION button.

EESignature

0 Likes