delete_block
Simulink システムからのブロックの削除
説明
例
絶対パス名を使用してブロックを削除する
vdp
システムから Mu ブロックを削除します。
open_system('vdp') delete_block('vdp/Mu')
ブロック ハンドルを使用してブロックを削除する
ブロック ハンドルを使用して vdp
システムから Out2 ブロックを削除します。
vdp
システムを開きます。
open_system('vdp')
Out1 ブロックを対話的に選択します。ブロックのハンドルを取得し、それを変数 Out1_handle
に代入します。ハンドルを使用してブロックを削除します。
Out1_handle = get_param(gcb,'Handle');
delete_block(Out1_handle)
ハンドルのベクトルを使用してブロックを削除する
vdp
システムから 3 つのブロックを削除します。
vdp
システムを開きます。3 つのブロックを追加し、それらのハンドルを変数に代入します。
open_system('vdp') Constant_handle = add_block('built-in/Constant','vdp/MyConstant'); Gain_handle = add_block('built-in/Gain','vdp/MyGain'); Outport_handle = add_block('built-in/Outport','vdp/MyOutport');
ハンドルのベクトルを使用して追加したブロックを削除します。
delete_block([Constant_handle Gain_handle Outport_handle])
入力引数
blockArg
— 削除するブロック
絶対パス名 | ハンドル | インデックスのベクトル | ハンドルまたはブロック パス名の 1 次元 cell 配列
削除するブロック。ブロックの絶対パス名、ハンドル、ハンドルのベクトル、ハンドルまたはブロック パス名の 1 次元 cell 配列として指定します。
例: 'vdp/Mu'
例: [handle1 handle2]
例: {'vdp/Mu' 'vdp/Out1' 'vdp/Out2'}
バージョン履歴
MATLAB コマンド
次の MATLAB コマンドに対応するリンクがクリックされました。
コマンドを MATLAB コマンド ウィンドウに入力して実行してください。Web ブラウザーは MATLAB コマンドをサポートしていません。
Select a Web Site
Choose a web site to get translated content where available and see local events and offers. Based on your location, we recommend that you select: .
You can also select a web site from the following list:
How to Get Best Site Performance
Select the China site (in Chinese or English) for best site performance. Other MathWorks country sites are not optimized for visits from your location.
Americas
- América Latina (Español)
- Canada (English)
- United States (English)
Europe
- Belgium (English)
- Denmark (English)
- Deutschland (Deutsch)
- España (Español)
- Finland (English)
- France (Français)
- Ireland (English)
- Italia (Italiano)
- Luxembourg (English)
- Netherlands (English)
- Norway (English)
- Österreich (Deutsch)
- Portugal (English)
- Sweden (English)
- Switzerland
- United Kingdom (English)