Jump to content

Back to previous site after running Unigui code


SergioFeitoza

Recommended Posts

Hi.

Suppose I am on some website and then I run a Unigui code that will open in the browser (auto-starting) . What should I do to, after run and close the Unigui code, the browser shows again the previous site?  My doubt is to know what and where to include the code to save the previous site and the same in the Close moment

Link to comment
Share on other sites

Thanks Sherzod. I will re-make my question in another way.

 I am now in the Unigui forum looking to your comment page. My Unigui code, in Delphi, is open. Now I run it (F9) using “auto starting.  The program opens. Then I click a “Close Button” within one of the forms. The code of the button is:

 

procedure TUniForm1.UniButton1Click(Sender: TObject);

begin

   UniApplication.Terminate('GoodBye');          // to put the app in a closed state in the browser

   PostThreadMessage(MainThreadID,wm_quit,0,0);  //  tell the main application to terminate

end;

 

Restart.png.9f660f44262b2e2041d8990a494522e1.pngThe program closes and I see the screen of the attachment. The tab in the left is the “forum page” which was in use before. This is what I want to see.

The tab “SwitchgearDesign” with the link “Restart Application”  (that I do not want to see)  remained open. I think that if this last one is closed. I will see only the forum page.

·         So, my question is, “ What I should include in the  “click” above to make the page “restart application” to disappear when I click the Close button ?.

Link to comment
Share on other sites

Hi Sherzod. Thanks.  After reading your comment I found this posthttp://forums.unigui.com/index.php?/topic/9225-closing-unigui-application/

After checking, I decided to maintain simply

procedure TUniForm1.UniButton1Click(Sender: TObject);

begin

   UniApplication.Terminate(' To close the application, just close the tab. To restart click below');    

end;

 

Then I came to another doubt. This final form is created by the application. The screen in the figure of the post is a “gris” one. How can I change the color of this form and the type of font of the message “Restart Application” ?

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...