Author Topic: search for a lsp to import dwg files to one dwg  (Read 1000 times)

0 Members and 1 Guest are viewing this topic.

Burzum

  • Mosquito
  • Posts: 2
search for a lsp to import dwg files to one dwg
« on: January 24, 2022, 04:36:50 AM »
Hi 

I have 400 dwg files (floorplans) in a folder, I would like to add them to one dwg file. They have same size. I would like to add them
[ ]  little place [ ]  little place 
like that, is there any solution?

It's Alive!

  • Retired
  • Needs a day job
  • Posts: 8703
  • AKA Daniel
Re: search for a lsp to import dwg files to one dwg
« Reply #1 on: January 24, 2022, 04:47:06 AM »
insert them as blocks

Burzum

  • Mosquito
  • Posts: 2
Re: search for a lsp to import dwg files to one dwg
« Reply #2 on: January 24, 2022, 06:27:15 AM »
and how do I insert the whole folder content of dwg files to one dwg?

mhupp

  • Bull Frog
  • Posts: 250
Re: search for a lsp to import dwg files to one dwg
« Reply #3 on: January 24, 2022, 07:34:46 AM »
and how do I insert the whole folder content of dwg files to one dwg?

Search for Insert Block Lisp's specifically "from folder" or "multiple"
https://lispbox.wordpress.com/2014/11/25/insert-dwg-from-a-folder-as-blocks-2/

sln8458

  • Newt
  • Posts: 91
  • CMS Intellicad 9.0/10.0
Re: search for a lsp to import dwg files to one dwg
« Reply #4 on: January 28, 2022, 05:40:43 AM »
I had to do something like this a couple of weeks back.

The client had sent over a DXF file, I had to extract all of the blocks, create a new drawing and the insert a number of the blocks into a new drawing. (This was a piping layout)
Each file was 'xref' into the new drawing on a new layer named as per the block.

I used a script for this, compiled in Excel, then pasted into notepad as a ***.scr:
Create the layer name & colour.
Set to the new layer.
Insert the Xref.
Move on to next file etc etc .......

Code: [Select]
(COMMAND "-layer" "N" "10IN-GH-90007-HG-1-PDK" "co" "132" "10IN-GH-90007-HG-1-PDK" "")(COMMAND "-layer" "S" "10IN-GH-90007-HG-1-PDK" "")(COMMAND "-xref" "A" "E:\\Stylemark Designs\\Project Folder\\nested folder\\second nested folder\\piping\\EXTS-PIPE-PANCAKE-DECK\\10IN-GH-90007-HG-1-PDK.dwg""0,0,0""1""1""")

cells are shown [ ], I then used used 'concatenate'

[10IN-GH-90007-HG-1-PDK]      [(COMMAND "-layer" "N"]   ["]   [" "]    ["co" "132"]        ["")]      [(COMMAND "-layer" "N" "10IN-GH-90007-HG-1-PDK" "co" "132" "10IN-GH-90007-HG-1-PDK" "")]

here is the final cell contents for the first command, repeat as required
[=CONCATENATE($H$60,$D$5,F120,$D$5,$L$60,$J$60,F120,$J$60,$N$120)
F120 is the file name (minus the '.dwg')

I had over 200 to do, pull the file names from explorer, one line per drawing.
All I had to do was create the base drawing and then run the script, took less than 5 mins to run

Steve
There is no such  thing as a 'silly question' to those who do not know!