[求助]请帮忙看一段代码,关于选择集的
<p>这是一段选择闭合多段线内图元的代码,多段线在函数外已被确定是闭合的,现在问题是这段代码一个图元都选择不到,而同一份数据我在vba里是能选择到的</p><p></p><p> private void SetAnnoInLWPolyLine(AcadDocument cadDoc, AcadLWPolyline cadLine, string strLayer)<br/> {</p><p> double[] coods = cadLine.Coordinates as double[];<br/> int coodCount = coods.Length / 2;<br/> if (coodCount < 3)<br/> return;</p><p> double[] coodsPolygon = new double;<br/> for (int i = 0; i < coodCount; i++)<br/> {<br/> coodsPolygon = coods;<br/> coodsPolygon[(3 * i) + 1] = coods[(2 * i) + 1];<br/> coodsPolygon[(3 * i) + 2] = 0;<br/> }<br/> <br/> AcadSelectionSet SeleSets = cadDoc.SelectionSets.Add("Temp");<br/> SeleSets.SelectByPolygon(AcSelect.acSelectionSetWindowPolygon, coodsPolygon, missobj, missobj);<br/> <br/> for (int i = 0; i < SeleSets.Count; i++)<br/> {<br/> AcadEntity ent = SeleSets.Item(i);<br/><br/> .........................<br/> }</p><p> SeleSets.Delete();<br/> <br/> }</p> <p>同一问题不要重复发帖!</p><p>关于字体的问题可以试下ObjectDbx</p>
页:
[1]