应用程序对象提供了用于设置和检索 AutoCAD 系统变量的 and 方法。例如,若要为 MAXSORT 系统变量赋值一个整数,请使用以下代码:SetSystemVariableGetSystemVariable VB.NET'' Get the current value from a system variable Dim nMaxSort as Integer = Application.GetSystemVariable("MAXSORT") '' Set system variable to new value Application.SetSystemVariable("MAXSORT", 100) C#// Get the current value from a system variable int nMaxSort = System.Convert.ToInt32(Application.GetSystemVariable("MAXSORT")); // Set system variable to new value Application.SetSystemVariable("MAXSORT", 100); VBA/ActiveX 代码参考'' Get the current value from a system variable Dim nMaxSort as Integer nMaxSort = ThisDrawing.GetVariable("MAXSORT") '' Set system variable to new value ThisDrawing.SetVariable "MAXSORT", 100 |
|Archiver|CAD开发者社区 ( 苏ICP备2022047690号-1 )
GMT+8, 2024-5-19 13:58
Powered by Discuz! X3.4
Copyright © 2001-2021, Tencent Cloud.