0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

AutoCAD VBA 指定名のブロック定義の分解の許可の状態を設定する

Posted at

指定名のブロック定義の分解の許可の状態を設定する

構文  : Call uSetBlockExplodability( aoDoc, aBlockName, aStatus )
引数1 : 図面             | aoDoc As AcadDocument
引数2 : ブロック定義名   | aBlockName As String
引数3 : 分解の許可の状態 | aStatus As Boolean
AutoCAD VBA
Public Sub uSetBlockExplodability(ByVal aoDoc As AcadDocument _
                           , ByVal aBlockName As String _
                              , ByVal aStatus As Boolean)
  ' 指定名のブロック定義を取得
  Dim oBlock As AcadBlock
  Set oBlock = uFnGetBlockByName(aoDoc:=aoDoc, aBlockName:=aBlockName)
  
  ' 指定名のブロック定義がなかったら終了
  If oBlock Is Nothing Then Exit Sub
  
  ' 指定名のブロック定義の分解の許可を設定
  oBlock.Explodable = aStatus
  
  ' オブジェクト変数の解放
  Set oBlock = Nothing
End Sub

uFnGetBlockByName() : 指定名のブロック定義を取得するFunction
については以下を確認してください

0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?