-
-
Notifications
You must be signed in to change notification settings - Fork 325
fmx DialogService.MessageDialog how to use arguments #507
-
DialogService.ShowMessage('hello')
work well
DialogService.MessageDialog('hello2', 'TMsgDlgType.mtInformation', ['mbYesNo'], 'TMsgDlgBtn.mbYes', 0)
result
"MessageDialog" called with invalid arguments.
Error: Expected and actual arguments are incompatible
Beta Was this translation helpful? Give feedback.
All reactions
This works:
DialogService.MessageDialog('hello2', 'mtInformation', ['mbYes', 'mbNo'], 'mbYes', 0, None)
Replies: 3 comments 1 reply
-
This works:
DialogService.MessageDialog('hello2', 'mtInformation', ['mbYes', 'mbNo'], 'mbYes', 0, None)
Beta Was this translation helpful? Give feedback.
All reactions
-
Beta Was this translation helpful? Give feedback.
All reactions
-
Of course since DialogService.MessageDialog is a procedure. I guess because on mobile platforms this is non-modal dialog.
class procedure MessageDialog(const AMessage: string; const ADialogType: TMsgDlgType;
const AButtons: TMsgDlgButtons; const ADefaultButton: TMsgDlgBtn; const AHelpCtx: THelpContext;
const ACloseDialogProc: TInputCloseDialogProc); overload;
I am afraid there is no way to provide a function for ACloseDialogProc. But you can use the procedure to show a simple message, with say an OK button (customizable version of ShowMessage).
@lmbelo Can we do some special wrapping of this and related functions?
Beta Was this translation helpful? Give feedback.
All reactions
-
Beta Was this translation helpful? Give feedback.