Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 9051931
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 16, 20262026-06-16T13:02:11+00:00 2026-06-16T13:02:11+00:00

I am trying to open webpage in another webview by using following code. In

  • 0

I am trying to open webpage in another webview by using following code. In this program i am using two webview in one test1.htm is displayed and i want on clicking the hyperlink in first webview the new page should open in another webview

class webcontrol extends JFrame
{

    webcontrol()
    {
        setLayout(null);
        Container cp=this.getContentPane();
        fxpanel= new JFXPanel();
        add(fxpanel);
        fxpanel.setBounds(660, 0, 230, screenSize.height-120);

        Platform.runLater(new Runnable() {
            public void run()
            {
                initFx(fxpanel,fxpanel1);
            }
        }
   );


 }

 private static void initFx(final JFXPanel fxpanel, JFXPanel fxpanel1)
 { 
     WebView webview=null,webview1=null;
     WebEngine eng=null,eng1=null; 
     Dimension screenSize = Toolkit.getDefaultToolkit().getScreenSize();

     Group group1= new Group();
     Scene scene1= new Scene(group1);
     fxpanel1.setScene(scene1);    

     webview1 = new WebView ();
     group1.getChildren().removeAll();
     group1.getChildren().add(webview1);

     Group group= new Group();
     Scene scene= new Scene(group);
     fxpanel.setScene(scene);    
     webview = new WebView ();
     group.getChildren().removeAll();

     group.getChildren().add(webview);


     eng= webview.getEngine();
     eng1=webview1.getEngine();
     File htmlFile = new File("d:/newfolder/test.htm");
     File htmlFile1 = new File("d:/newfolder/test1.htm");
     try
     {
         eng.load(htmlFile.toURI().toURL().toString());
         eng1.load(htmlFile1.toURI().toURL().toString());
     }
     catch(Exception ex)
     {
         ex.printStackTrace();
     }
 }


         }
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-16T13:02:13+00:00Added an answer on June 16, 2026 at 1:02 pm

    There is no closing of String in:

    ("d:/newfolder/test1.htm);
    

    Where as

    ("d:/newfolder/test.htm");
    

    is fine.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I´m trying to open a tab using jquery, here is my code: $(#ecContenedorFolders).tabs({ tabTemplate:
I'm trying to parse a webpage using open-uri + hpricot but it seems to
I'm trying to open a webpage using urllib.request.urlopen() then search it with regular expressions,
I am trying open a new window using url.Action. And the new Window url
I'm trying to open a file for input in Excel with this line :
I'm trying to open a zip file with jython using FileInputStream and ZipInputStream. But
I am trying to code this from scratch, so that when a button clicked
I'm trying to write a Windows command file to open a webpage in IE,
I'm trying to open multiple URL's input streams, here's my current code FileInputStream fi
I'm trying to add a cookie to a webpage using python's Cookie so I

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.