AutoCAD 2013/2014/2015

Reply
Valued Mentor
sthompson1021
Posts: 470
Registered: ‎03-02-2010
Message 1 of 7 (783 Views)
Accepted Solution

Insert multiple blocks using script

783 Views, 6 Replies
11-15-2013 08:56 AM

Can anyone tell me whats wrong with this script? It inserts the first block and then quits. I had to change the the file to a txt to get it to upload

Active Member
scottwilcox1989
Posts: 6
Registered: ‎04-04-2013
Message 2 of 7 (770 Views)

Re: Insert multiple blocks using script

11-15-2013 09:17 AM in reply to: sthompson1021

You may only need 1 0 instead of 1 1 0 in your script, which defines the scale and rotation angle.
Also, do you need a minus sign "-" in front of your insert command? like so? -INSERT

 

*EDIT*  Try adding a leading space for the third line onwards.

Valued Mentor
sthompson1021
Posts: 470
Registered: ‎03-02-2010
Message 3 of 7 (761 Views)

Re: Insert multiple blocks using script

11-15-2013 10:01 AM in reply to: scottwilcox1989

Thanks for the reply, unfortunately nothing worked.

I get this in the text window when it stops.

 

Valued Mentor
sthompson1021
Posts: 470
Registered: ‎03-02-2010
Message 4 of 7 (724 Views)

Re: Insert multiple blocks using script

11-15-2013 12:02 PM in reply to: sthompson1021

After a lot of messing around, I found that I had to put in the block name after each set of coordinates. Also a kudo to scottwilcox as he was right about only needing 1 0 after the coordinates

Active Member
scottwilcox1989
Posts: 6
Registered: ‎04-04-2013
Message 5 of 7 (709 Views)

Re: Insert multiple blocks using script

11-15-2013 01:30 PM in reply to: sthompson1021

FYI, this worked on my AutoCAD 2011:

 

Valued Mentor
sthompson1021
Posts: 470
Registered: ‎03-02-2010
Message 6 of 7 (701 Views)

Re: Insert multiple blocks using script

11-15-2013 02:04 PM in reply to: scottwilcox1989

Hey, it works on my 2014 too... I could have sworn I tried it like that but I must have had something different. Thanks for the info.

New Member
DJKsnr
Posts: 1
Registered: ‎11-20-2013
Message 7 of 7 (645 Views)

Re: Insert multiple blocks using script

11-20-2013 01:31 AM in reply to: sthompson1021

If you have the information in excel you can copy this into a word document.  Save as plain txt, inserting line breaks.  Change the extension from txt to scr

You are not logged in.

Log into access your profile, ask and answer questions, share ideas and more. Haven't signed up yet? Register

Announcements
Are you familiar with the Autodesk Expert Elites? The Expert Elite program is made up of customers that help other customers by sharing knowledge and exemplifying an engaging style of collaboration. To learn more, please visit our Expert Elite website.

Need installation help?

Start with some of our most frequented solutions to get help installing your software.

Ask the Community




Connect with AutoCAD

Twitter

Facebook

Blogs

Pinterest

Youtube