Hello,
Can I somehow prevent closing TMSFNCTaskDialog window?
Let's say I have an Fnc edit on it:
Var MyEdit : TTMSFNCEdit := TTMSFNCEdit.Create(TaskDialog);//uses FMX.TMSFNCEdit
MyEdit.Parent := TaskDialog;
MyEdit.EditType := etNumeric;
MyEdit.Text := 0 ;
MyEdit.Width := 100;
TaskDialog.InputType := titCustom; // titEdit titDate titCustom titNone
TaskDialog.InputControl := MyEdit;
TaskDialog.Execute(
procedure(ModalResult: TModalResult)
begin
case ModalResult of
mrOk:
Begin
TaskDialog.InputText := MyEdit.Text;
Do something else
end;
End;
end);
... and I would like to allow to be closed only if the user enters a number between 1 and 49 (e.g. 49 is the maximum piece the customer can take of the selected product).
First I thought of the OnDialogButtonClick, but this doesn't have a parameter to block closing it like the OnCloseQuery event for a form (CanClose parameter).
Thank you!