Vcl.DBCtrls.TDBRichEdit.OnProtectChange

提供: RAD Studio API Documentation
移動先: 案内検索

Delphi

property OnProtectChange: TRichEditProtectChange read FOnProtectChange write FOnProtectChange;

C++

__property OnProtectChange;

プロパティ

種類 可視性 ソース ユニット
event published
Vcl.DBCtrls.pas
Vcl.DBCtrls.hpp
Vcl.DBCtrls TDBRichEdit

説明

protected とマークされたテキストをユーザーが変更しようとした際に発生します。

Vcl.DBCtrls.TDBRichEdit.OnProtectChange は Vcl.ComCtrls.TCustomRichEdit.OnProtectChange を継承しています。以下の内容はすべて Vcl.ComCtrls.TCustomRichEdit.OnProtectChange を参照しています。

protected とマークされたテキストをユーザーが変更しようとした際に発生します。

OnProtectChange イベント ハンドラを記述すると、protected 属性のテキストの変更が可能になります。StartPos および EndPos パラメータは、変更の影響を受けるテキストの範囲の最初と最後を示します。このとき、0 はテキストの最初の文字です。protected テキストを変更可能にするには、AllowChange を True に設定します。

テキストのセクションに対して protected 属性を設定または設定解除するには、テキストを選択し、リッチ編集コントロールの SelAttributes プロパティの Protected プロパティを使用します。デフォルトでテキストが protected 属性を持つようにするには、リッチ編集オブジェクトの DefAttributes プロパティの Protected プロパティを使用します。

関連項目