Jump to content

baquelo

Members
  • Content Count

    3
  • Joined

  • Last visited

Posts posted by baquelo


  1. 7 hours ago, Rollo62 said:

    I always consider the Application.ProcessMessages suspicious, do you really need this ?

    Usualy I'm fine when reacting to my stuff directly in the anonymous procedure.

    I'm a beginner in Delphi and I picked up a project in the company where the programmer used the code that way. I was just migrating the Delphi 10.1 project to Delphi 10.3. I did not really think about using the anonymous procedure. Soon I will reinstall Delphi 10.3 and I will proceed to use the anonymous procedure. Many thanks for the reply.


  2. On 1/16/2019 at 4:10 PM, mausmb said:

    This code working just fine in 10.3 Android & Windows ... dont' know with Tmodalresult

    
      TDialogService.MessageDialog((mymessage),
          system.UITypes.TMsgDlgType.mtConfirmation,
          [system.UITypes.TMsgDlgBtn.mbYes, system.UITypes.TMsgDlgBtn.mbNo], system.UITypes.TMsgDlgBtn.mbYes,0,
    procedure (const AResult: System.UITypes.TModalResult)
      begin
              case AResult of
                mrYES: Begin .....

    br,

    Thanks for reply! I reinstall Delphi 10.1.


  3. Hi!!

    I need a confirmation box (Yes and No options) in Android, but in Delphi 10.3 dont work, the app crash... In the Delphi 10.1 work fine...

     

    Function TForm1.mensagemConfirmacao(pMensagem: String): TModalResult;
    Var
      MR: TModalResult;
    Begin
      MR := mrNone;
      TDialogService.MessageDialog(pMensagem, TMsgDlgType.mtConfirmation,
        [TMsgDlgBtn.mbYes, TMsgDlgBtn.mbNo], TMsgDlgBtn.mbYes, 0,
        Procedure(Const AResult: TModalResult)
        Begin
          MR := AResult;
        End);
      While MR = mrNone Do
      begin
        Application.ProcessMessages;
      end;
      result := MR;
    End;



    Help me please!!

×