如何修复“ java未命名模块从y和z读取包x”

时间:2019-07-19 19:28:40

标签: java javafx htmlunit

我是Java新手。我正在尝试使用htmlunit登录网站。我得到这些错误。我该如何解决。它的JDK11。这是我的代码:

try {
    WebClient webClient = new WebClient();

    HtmlPage page = (HtmlPage) 
    webClient.getPage("http://ubs.yalova.edu.tr");
    HtmlForm form = page.getFormByName("loginForm");
    form.getInputByName("username").setValueAttribute("myUsername");
    form.getInputByName("password").setValueAttribute("myPassword");

    page = form.getInputByValue("GİRİŞ YAP").click();

    System.out.println(page.asText());
   } catch (IOException e)
   {
       e.printStackTrace();
   }

//module-info.java
    module HelloWorld {
    requires javafx.controls;
    requires javafx.fxml;
    requires htmlunit;

    opens sample;
}

此处所有错误:https://paste.ubuntu.com/p/Cm7m23RcjS/

0 个答案:

没有答案