Vcl.Dialogs.InputQuery
Delphi
function InputQuery(const ACaption: string; const APrompts: array of string; var AValues: array of string; CloseQueryFunc: TInputCloseQueryFunc): Boolean;
function InputQuery(const ACaption: string; const APrompts: array of string; var AValues: array of string; CloseQueryEvent: TInputCloseQueryEvent; Context: TObject): Boolean;
function InputQuery(const ACaption, APrompt: string; var Value: string): Boolean;
C++
extern DELPHI_PACKAGE bool __fastcall InputQuery(const System::UnicodeString ACaption, const System::UnicodeString *APrompts, const System::NativeInt APrompts_High, System::UnicodeString *AValues, const System::NativeInt AValues_High, _di_TInputCloseQueryFunc CloseQueryFunc = _di_TInputCloseQueryFunc())/* overload */;
プロパティ
種類 | 可視性 | ソース | ユニット | 親 |
---|---|---|---|---|
function | public | Vcl.Dialogs.pas Vcl.Dialogs.hpp |
Vcl.Dialogs | Vcl.Dialogs |
説明
文字列、実数、整数のいずれかをユーザーが入力できる入力ダイアログ ボックスを表示します。
InputQuery を呼び出すと、文字列、実数、整数のいずれかをユーザーが入力できる入力ダイアログ ボックスを表示します。
ACaption はダイアログ ボックスのキャプションです。
APrompt は編集ボックスにユーザーが入力するテキストです。
Value は、ダイアログ ボックスが最初に表示されたときに、編集ボックスに表示される値です。ユーザーが入力した値が返ります。
InputQuery では、ユーザーが [OK] を選択したときに true、[キャンセル] を選択したとき、または Esc キーを押したときに false が返ります。
ユーザーがダイアログをキャンセルしたときに、デフォルト値を使用する必要がある場合は、InputBox を代わりに使用します。