该对象提供了一组用于创建和操作保存的图层状态的函数。使用以下函数处理图层状态:LayerStateManagerLayerStateManager
可以使用对象的属性访问数据库的对象。LayerStateManagerLayerManagerStateDatabase VB.NETDim acDoc As Document = Application.DocumentManager.MdiActiveDocument Dim acCurDb As Database = acDoc.Database Dim acLyrStMan As LayerStateManager acLyrStMan = acCurDb.LayerStateManager C#Document acDoc = Application.DocumentManager.MdiActiveDocument; Database acCurDb = acDoc.Database; LayerStateManager acLyrStMan; acLyrStMan = acCurDb.LayerStateManager; VBA/ActiveX 代码参考检索对象后,必须先将数据库与其关联,然后才能访问对象的方法。使用该方法将数据库与LayerStateManagerSetDatabaseLayerStateManager. Dim oLSM As AcadLayerStateManager
Set oLSM = ThisDrawing.Application. _
GetInterfaceObject("AutoCAD.AcadLayerStateManager.24")
oLSM.SetDatabase ThisDrawing.Database
父主题: |
|Archiver|CAD开发者社区 ( 苏ICP备2022047690号-1 苏公网安备32011402011833)
GMT+8, 2025-1-8 19:40
Powered by Discuz! X3.4
Copyright © 2001-2021, Tencent Cloud.