zoukankan      html  css  js  c++  java
  • 选择集

    1、根据图块名过滤

    Dim tksTV(0) As DatabaseServices.TypedValue
    tksTV.SetValue(New DatabaseServices.TypedValue(DatabaseServices.DxfCode.BlockName, tkNames), 0)
    Dim tksFilter As New EditorInput.SelectionFilter(tksTV)
    Dim tksPSR As Autodesk.AutoCAD.EditorInput.PromptSelectionResult
    tksPSR = doc.Editor.GetSelection(tksFilter)

     2、选择图块

    Dim doc As Autodesk.AutoCAD.ApplicationServices.Document = Autodesk.AutoCAD.ApplicationServices.Application.DocumentManager.MdiActiveDocument
    Dim pso As PromptSelectionOptions = New PromptSelectionOptions()
            With pso
                .RejectObjectsOnLockedLayers = True
                .AllowSubSelections = False
                .MessageForAdding = "选择图块"
                .MessageForRemoval = "选择图块"
            End With
    
            Dim filList() As TypedValue = {New TypedValue(0, "Insert")}
            Dim filter As New SelectionFilter(filList)
            Dim psr As PromptSelectionResult = Autodesk.AutoCAD.ApplicationServices.Application.DocumentManager.MdiActiveDocument.Editor.GetSelection(pso, filter)
            If Not psr.Status = PromptStatus.OK Then
                doc.Editor.WriteMessage(vbLf & "命令:")
                Exit Sub
            End If
  • 相关阅读:
    HTTP协议详解
    如何编写出拥抱变化的代码
    Cookie ,Session
    Request 请求
    MySQL如何处理死锁
    如何优化冒泡排序
    java数据结构分析
    response响应
    Tomcat服务器
    HTTP协议
  • 原文地址:https://www.cnblogs.com/rf8862/p/13956390.html
Copyright © 2011-2022 走看看