Warning: file_get_contents(/data/phpspider/zhask/data//catemap/9/java/394.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Java 如何从LCDUI表单启动LWUIT表单?_Java_Java Me_Lwuit_Lcdui_Lwuit Form - Fatal编程技术网

Java 如何从LCDUI表单启动LWUIT表单?

Java 如何从LCDUI表单启动LWUIT表单?,java,java-me,lwuit,lcdui,lwuit-form,Java,Java Me,Lwuit,Lcdui,Lwuit Form,在前面的一些问题中,这个问题被间接地提到了,但我没有看到任何决定性的东西 我目前正在使用这段代码来显示CommandAction实现中的LWUIT表单 public void commandAction(Command cmnd, Item item) { if (item == LogIn && cmnd == maincommand) { RechForm = new com.sun.lwuit.Form("Basefook"); HttpReque

在前面的一些问题中,这个问题被间接地提到了,但我没有看到任何决定性的东西

我目前正在使用这段代码来显示
CommandAction
实现中的LWUIT表单

public void commandAction(Command cmnd, Item item) {

if (item == LogIn && cmnd == maincommand) {
RechForm = new com.sun.lwuit.Form("Basefook");
            HttpRequestHandler handler = new HttpRequestHandler();
            HTMLComponent htmlc = new HTMLComponent(handler);
            htmlc.setPage("http://facebook.com");
            RechForm.addComponent(BorderLayout.CENTER, htmlc);
            com.sun.lwuit.Display.init(this);
            RechForm.show();

}

}
目前它没有打开表单,也没有崩溃


如果这是不可能的,那么你能为基于MIDP的lcdui的某种浏览器控件提出一个解决方案吗

解决了它。它现在可以工作了。只需将
com.sun.lwuit.Display.init(这个)进入
startApp()
改变

RechForm.addComponent(BorderLayout.CENTER, htmlc);

RechForm.addComponent(htmlc);