Visual LISP, AutoLISP and General Customization
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

copy layers'name (NOT GEOMETRIES) from multiple .dwg to ONE .dwg

6 REPLIES 6
SOLVED
Reply
Message 1 of 7
sabysaby
1054 Views, 6 Replies

copy layers'name (NOT GEOMETRIES) from multiple .dwg to ONE .dwg

Hi all!
I need to create ONE dwg (called "structure.dwg") containing ALL, AND ONLY!, the layers'names (NOT THEIR GEOMETRIES!) coming from other 1000 dwg.

Does exist a lisp rountine that can automate that?

Thanks in advance!

Saby

 

Tags (3)
6 REPLIES 6
Message 2 of 7
Lee_Mac
in reply to: sabysaby

You could automate my Steal program to perform this task.

Message 3 of 7
sabysaby
in reply to: Lee_Mac

WOW!
It's great!

Thanks very much for now, but....I've got another little question:

How can I select more than one dwg to import their layers once in the same time?

The "select drawing to steal from" window doesn't allow me to make a mutiple dwg selection......

Have I to use "STEALALL" one dwg by one?

Instead, using STEALTEMPLATES, I can select multiple .dwt files.

Is there an alternative methods of saving all my dwg in a dwt format?

Thanks in advance for everything!!
Saby

 

 

 

Message 4 of 7
Lee_Mac
in reply to: sabysaby

Hi Saby,

 

Thank you, I'm glad you like the program Smiley Happy

 

For multiple drawings, load my Steal program and also load this program, and then run the following code:

 

(defun c:stealdwgs nil
    (foreach dwg (LM:getfiles "Select Drawings to Steal from" nil "dwg")
        (Steal dwg
           '(
                ;; Items to Steal:
                ;;--------------------------------
                ;("Blocks"                  ("*"))
                 ("Layers"                  ("*"))
                ;("Linetypes"               ("*"))
                ;("Text Styles"             ("*"))
                ;("Dimension Styles"        ("*"))
                ;("Layouts"                 ("*"))
                ;("Views"                   ("*"))
                ;("Materials"               ("*"))
                ;("Viewports"               ("*"))
                ;("Page Setups"             ("*"))
                ;("User Coordinate Systems" ("*"))
                ;("Groups"                  ("*"))
                ;("Drawing Properties"      ("*"))
                ;("Custom Properties"       ("*"))
                ;("Multileader Styles"      ("*"))
                ;("Multiline Styles"        ("*"))
                ;("Table Styles"            ("*"))
                ;("Scales"                  ("*"))
                ;("Layer States"            ("*"))
            )
        )
    )
    (princ)
)

 

The above is currently set to import only LAYERS - you can uncomment (remove the semi-colon) to control which collections are imported.

 

Lee

Message 5 of 7
sabysaby
in reply to: Lee_Mac

WOW!!Great!!!!

You are a genius!!
You made my day!!

You solved me a great problem, that's why I've just made you a donation to thank you!!
Saby

 

ps

I'm going to post a new "little" problem called "check elevation/Z geometries errors"... maybe you could help me again!

🙂

 

 

Message 6 of 7
Lee_Mac
in reply to: sabysaby

That's incredibly kind of you Saby, thank you very much indeed Smiley Happy

Message 7 of 7
Anonymous
in reply to: Lee_Mac

I have downloaded the Steal file but it only copied the layer name. I need to copy the content of the layer.

Also I need copy the layers from 3600 .dwg to a single dwg.

 

Please can you assist with this?

Can't find what you're looking for? Ask the community or share your knowledge.

Post to forums  

Autodesk Design & Make Report

”Boost