hamze Posted January 6, 2015 Share Posted January 6, 2015 Not run in tandem coding F_Waite.ShowModal(); ShowMessage(''); The application form is not close until the message can not be displayed مشکل من اینه که در اپلیکشن تا زمانی که کاربر فرم مودال شده را نبندد پیغام نمایش داده نمیشود. در صورتی که در این فریمورک اینطور نیست و همه را اجرا میکند. Consecutive messages will be displayed. و مورد بعدی چرا چند پیغام که پشت سر هم میگزاریم فقط یکی از انها را نمایش میدهد. Quote Link to comment Share on other sites More sharing options...
Administrators Farshad Mohajeri Posted January 6, 2015 Administrators Share Posted January 6, 2015 uniGUI modal will not block thread execution. use Callbacks instead. Quote Link to comment Share on other sites More sharing options...
hamze Posted January 7, 2015 Author Share Posted January 7, 2015 uniGUI modal will not block thread execution. use Callbacks instead. thanks for answering Did not get your answer.Can explain more? please answer to second question. Quote Link to comment Share on other sites More sharing options...
Administrators Farshad Mohajeri Posted January 7, 2015 Administrators Share Posted January 7, 2015 Correct way of using form call backs: Under demos folder: Dialogs Dialogs Anonymous Callback Form Callback Form Anonymous Callback 1 Quote Link to comment Share on other sites More sharing options...
Administrators Farshad Mohajeri Posted January 7, 2015 Administrators Share Posted January 7, 2015 Consecutive messages will be displayed. You can not show a 2nd messagebox while first one is still active. It is limited by design. 1 Quote Link to comment Share on other sites More sharing options...
Abaksoft Posted February 19, 2015 Share Posted February 19, 2015 Farshad said : >> uniGUI modal will not block thread execution. use Callbacks instead. Today, I discovered this. If I understand, we don't use code after ShowModal ========================================== The code just after a showModal is executed and don't wait ! ========================================== procedure TMainForm.UniButton1Click(Sender: TObject); begin //1. unit3.UniForm3.ShowModal(NextCode); //2. NEVER write code after ShowModal : it not stoped by showModal !!! ??? // Showmessage('I am Here '); // if I understand, always write code after showModal in a procedure exemple : NextCode // is it True ? end; procedure TMainForm.NextCode(Sender: TComponent; AResult: Integer); begin if AResult=1 then showMessage('Do this .... ') else showMessage('Canceled'); end; ShowModal_Behavior.zip Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.