Blog post "Delphi XE5 Anonymous ShowModal and Android" at http://blog.marcocantu.com/blog/xe5_anonymous_showmodal_android.html

Blog post "Delphi XE5 Anonymous ShowModal and Android" at http://blog.marcocantu.com/blog/xe5_anonymous_showmodal_android.html
http://blog.marcocantu.com/blog/xe5_anonymous_showmodal_android.html

Comments

  1. thanks for sharing here, I have just coded that after digging Embarcadero docs.
    I also have to modify my code as
    private methods are not allowed. Call an internal procedure is not possible.

    ReplyDelete
  2. Even being able to get the ModalResult, the calling form had their next statements executed. The flow was not exactly as would I expect.
    Ex:
    Form2.ShowModal(procedure... if ModalResult=mrOK then myProc1() ...);
    myProc2();

    Problem is thay myProc2() is called FIRST. If I have more lines to be processed after showmodal, they will be, after finish at the "end;" so the Form2 is shown and finally I could execute myProc1();
    The expected was to exec (or not) myProc1 and after all, myProc2 and so on...
    Have I forgot something or this correct?

    ReplyDelete
  3. you probably need to add myProc2() in the anonymous method

    ReplyDelete
  4. Yes, I just figured out that Cantù! Thank you. Everything we want to behaviour as ShowModal should be inside anonymous method.

    ReplyDelete
  5. Hi

    one thing about this method is that because it blocks messages...it will block things like clipboard, if that is used on the form you are using in the showmodal...at least that is what I found out...:)

    ReplyDelete
  6. Brian Hamilton that should not happen, exactly because this not really modal and it is just an extra regular form on top of the others. I mean, if you see that error there is likely a different cause.

    ReplyDelete
  7. Hi
    I came across this while trying to use the call back from the zbar QR reader code...for when using this modal code for opening that form....with out that in use, it seemed that the call back message from the clipboard got lost or blocked

    ReplyDelete
  8. Hi Marco Cantù, can you share some sample application so that we can have look. Thx

    ReplyDelete
  9. Delphi sucks! GRRRR!!!!!!!!!!
    Appcelerator Titanium is better!

    ReplyDelete

Post a Comment