Jump to content

Excited about uniGUI - plus question about onclose()


aem

Recommended Posts

Hello,

  It's been a long time since I've been this excited about coding - UniGUI is amazing!

I hope I can be a useful part of this growing community.

 

So I am putting together a couple of demos to show our director next week

(healthcare software developer, 20 employees - purchase imminent)

Mostly I have ported over 2 ancient projects in record time that most thought were a lost cause.

 

I have a question already about closing/not closing forms.

For nice compatibility I have enablesynchronousoperations set to true.

The code often displays a form with    <otherform>.showmodal;

The code nicely stops there and waits for the form to close.

But without an onclosequery event that new form must determine if it is allowed to close

in the onclose() handler and set  action:=caNone  if it should remain active.

 

Here;s the rub,

Setting action:=canone does indeed keep the form on top

BUT

The statements immediately past the original showmodal call are executed no matter what I set the action value to.

 

This really reeks havoc where we use something like:

if <otherform>.showmodal=mrOK

    begin 

    //statements 

   end

else

   begin 

    //statements   

end;

These statements get hit while the form is still suppose to be in control and not yet closed.

In short, I can set the action:=canone and it keeps the top form showing,

but the calling code continues on past at that time - as if it had been closed.

I have been working with unigui for all of a week so I bet this is a newbie question.

 

Thanks,

aem

  • Like 1
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...