Array+Layers的应用
<p></p><p>Sub SetLayer()<br/> Dim LayerArray, LayerColorArray<br/> LayerArray = Array("粗实线", "虚线", "细实线", "中心线", "点划线", "尺寸线", "文本线")<br/> LayerColorArray = Array(1, 255, 3, 6, 4, 6, 2)<br/> Dim TestLayer As AcadLayer<br/> For ii = 0 To UBound(LayerArray) - 1<br/> Set TestLayer = ThisDrawing.Layers.Add(LayerArray(ii))<br/> TestLayer.color = LayerColorArray(ii)<br/> Next ii<br/>End Sub<br/></p>
页:
[1]