Community
AutoCAD Forum
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

-PDFimport as block automation

2 REPLIES 2
SOLVED
Reply
Message 1 of 3
Anonymous
675 Views, 2 Replies

-PDFimport as block automation

Hi all,

I'm using python to automate insertions of PDFs into DWGs through the PDFimport functionality.

PDFimport dialogue box allows you to check the "import as a block" setting which prevents autocad from creating layers for the imported PDF.

 

Is there a way to pass this setting as an argument to the -PDFIMPORT command? as I'm using the SendCommand and Autocad APIs.

2 REPLIES 2
Message 2 of 3
Alfred.NESWADBA
in reply to: Anonymous

Hi,

 

>> check the "import as a block" setting which prevents

>> autocad from creating layers

Sorry, incorrect. Importing it as block or not as block does not make a difference for importing the layers into AutoCAD.

There you can see the 2 different options, one for layer and the other for "as block"

 

20181106_093917.png

 

>> Is there a way to pass this setting as an argument to the

>> -PDFIMPORT command? 

For the "as block" option you can first set the variable PDFIMPORTMODE (>>>details<<<) to match your needs, for adding layers or not you can preset the variable PDFIMPORTLAYERS (>>>details<<<).

 

>> I'm using the SendCommand

I would avoid that as you don't get any errors or confirmation if the command succeeded or not.

 

- alfred -

------------------------------------------------------------------------------------
Alfred NESWADBA
ISH-Solutions GmbH / Ingenieur Studio HOLLAUS
www.ish-solutions.at ... blog.ish-solutions.at ... LinkedIn ... CDay 2024
------------------------------------------------------------------------------------

(not an Autodesk consultant)
Message 3 of 3
Anonymous
in reply to: Alfred.NESWADBA

Thank you indefinitely, that was really helpful. What do you suggest for automation instead of SendCommand

I'm using Python.

 

Regards,

Walid

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

Post to forums  

AutoCAD Inside the Factory


Autodesk Design & Make Report