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 指定名のブロック定義の分解の許可の状態を設定する

0
Last updated at Posted at 2025-04-17

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

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

zfGetBlockByName() : 指定名のブロック定義を取得する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?