AutoCAD .DXF Import Automation Options

 

When the program is driven from an automation script, an options string can be specified in the script that acts as the import options dialogs do in the program. The string consists of comma-separated parameters, which specify the behavior of the various import options.

 

Parameter

Type

Description

Filter

string

DXF

ApplyViewAngle

1 or 0

Apply the viewing angle, if there is one, to the image. 1 applies the view angle. 0 does not.

SkipPaperspace

1 or 0

Import any paperspace entities in the dxf drawing. 1 imports the paper space objects. 0 does not.

 

Example

This example shows how to import a DXF file with the various options.

 

CommandApi.Construct("Import")

CommandApi.Option("GuiEnabled", "False")

CommandApi.Option("Filter", "dxf")

CommandApi.Option("Options", "ApplyViewAngle=1;SkipPaperspace=0")

CommandApi.Option("Path", "C:/Path/To/Import/file.dxf")

CommandApi.Option("PersistOptions", "True")

CommandApi.Do() 

 

Used by: Import

 

 

See Also

Automation Model