CAD开发者社区

 找回密码
 立即注册

QQ登录

只需一步,快速开始

ActiveX 开发指南

相关分类

模型类型属性 (ActiveX)

2023-1-3 10:45| 发布者: admin| 查看: 415| 评论: 0|来自: AutoCAD

摘要: 指定打印配置是应用于模型空间还是应用于所有布局。

指定打印配置是应用于模型空间还是应用于所有布局。

支持的平台:仅窗口

签名

工 务 局:

object.ModelType
对象

类型:布局绘图配置

此属性适用的对象。

属性值

只读:是的

类型:布尔

  • True:打印配置仅适用于“模型空间”选项卡,或者布局是模型空间布局。
  • False:打印配置适用于所有布局,或者布局是图纸空间布局。

言论

没有额外的评论。

例子

工 务 局:

Sub Example_ModelType()
    ' This example creates a plot configuration object
    ' and then finds the ModelType for the object.
    
    Dim PlotConfigObj As AcadPlotConfiguration

    ' Creates the MText Object
    Set PlotConfigObj = ThisDrawing.PlotConfigurations.Add("NewPlotConfiguration")
    
    ' Find the current ModelType
    Dim currModelType As Boolean
    currModelType = PlotConfigObj.ModelType
    MsgBox "The ModelType for the object is: " & currModelType
    
End Sub

Visual LISP:

(vl-load-com)
(defun c:Example_ModelType()
    ;; This example creates a plot configuration object
    ;; and then finds the ModelType for the object.
    (setq acadObj (vlax-get-acad-object))
    (setq doc (vla-get-ActiveDocument acadObj))    

    ;; Creates the MText Object
    (setq PlotConfigObj (vla-Add (vla-get-PlotConfigurations doc) "NewPlotConfiguration"))
    
    ;; Find the current ModelType
    (setq currModelType (vla-get-ModelType PlotConfigObj))
    (alert (strcat "The ModelType for the object is: " (if (= currModelType :vlax-true) "True" "False")))
)

路过

雷人

握手

鲜花

鸡蛋

最新评论

QQ|Archiver|CAD开发者社区 ( 苏ICP备2022047690号-1 )

GMT+8, 2024-5-12 17:35

Powered by Discuz! X3.4

Copyright © 2001-2021, Tencent Cloud.

返回顶部