Vcl.Forms.TCustomForm.ActiveControl

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

Delphi

property ActiveControl: TWinControl read FActiveControl write SetActiveControl

C++

__property Vcl::Controls::TWinControl* ActiveControl = {read=FActiveControl, write=SetActiveControl, stored=IsForm};

プロパティ

種類 可視性 ソース ユニット
property public
Vcl.Forms.pas
Vcl.Forms.hpp
Vcl.Forms TCustomForm

説明

フォーム上でフォーカスがあるコントロールを示します。

ActiveControl プロパティを使用すると,フォーム上でフォーカスがあるコントロールを取得または設定できます。アプリケーション内で一度にフォーカスを持つことができるのは 1 つのコントロールだけです。

フォームにフォーカスがない場合は,ActiveControl は,フォームがフォーカスを受け取ったときにフォーカスを受け取ることになるフォーム上のコントロールを示します。

メモ:  フォーカスが別のコントロールに移ると,OnExit イベントが発生する前に ActiveControl の値が更新されます。

関連項目