Dear all,
I'm trying to run applet into one of my OFBiz pages, I included ftl file (I had replcaed all path for absolute for a while): <!--"CONVERTED_APPLET"--> <!-- HTML CONVERTER --> <SCRIPT LANGUAGE="JavaScript"><!-- var _info = navigator.userAgent; var _ns = false; var _ns6 = false; var _ie = (_info.indexOf("MSIE") > 0 && _info.indexOf("Win") > 0 && _info.indexOf("Windows 3.1") < 0); //--></SCRIPT> <COMMENT> <SCRIPT LANGUAGE="JavaScript1.1"><!-- var _ns = (navigator.appName.indexOf("Netscape") >= 0 && ((_info.indexOf("Win") > 0 && _info.indexOf("Win16") < 0 && java.lang.System.getProperty("os.version").indexOf("3.5") < 0) || (_info.indexOf("Sun") > 0) || (_info.indexOf("Linux") > 0) || (_info.indexOf("AIX") > 0) || (_info.indexOf("OS/2") > 0))); var _ns6 = ((_ns == true) && (_info.indexOf("Mozilla/5") >= 0)); //--></SCRIPT> </COMMENT> <SCRIPT LANGUAGE="JavaScript"><!-- if (_ie == true) document.writeln('<OBJECT classid="clsid:8AD9C840-044E-11D1-B3E9-00805F499D93" WIDTH = "600" HEIGHT = "400" codebase="http://java.sun.com/products/plugin/1.1.2/jinstall-112-win32.c ab#Version=1,1,2,0"><NOEMBED><XMP>'); else if (_ns == true && _ns6 == false) document.writeln('<EMBED type="application/x-java-applet;version=1.1.2" CODE = "org.ofbiz.webapp.applet.EmbeddedViewerApplet" CODEBASE = "C:/workspace/ofbiz/framework/webapp/build/lib" ARCHIVE = "jasperreports-0.6.0-applet.jar" WIDTH = "600" HEIGHT = "400" REPORT_URL = "/testReport" scriptable=false pluginspage="http://java.sun.com/products/plugin/1.1.2/plugin-install.ht ml"><NOEMBED><XMP>'); //--></SCRIPT> <APPLET CODE = "org.ofbiz.webapp.applet.EmbeddedViewerApplet" CODEBASE = "C:/workspace/ofbiz/framework/webapp/build/lib" ARCHIVE = "jasperreports-0.6.0-applet.jar,ofbiz-webapp.jar" WIDTH = "600" HEIGHT = "400"></XMP> <PARAM NAME = CODE VALUE = "org.ofbiz.webapp.applet.EmbeddedViewerApplet" > <PARAM NAME = CODEBASE VALUE = "C:/workspace/ofbiz/framework/webapp/build/lib" > <PARAM NAME = ARCHIVE VALUE = "jasperreports-0.6.0-applet.jar,ofbiz-webapp.jar" > <PARAM NAME="type" VALUE="application/x-java-applet;version=1.2.2"> <PARAM NAME="scriptable" VALUE="false"> <PARAM NAME = "REPORT_URL" VALUE ="/testReport"> </APPLET> </NOEMBED> </EMBED> </OBJECT> <!--"END_CONVERTED_APPLET"--> For the controller <request-map uri="main"> <security https="true" auth="true"/> <response name="success" type="view" value="main"/> </request-map> And the screen is <screen name="Main"> <section> <actions> <set field="title" value="Main Page"/> <set field="titleProperty" value="MainPage"/> <set field="headerItem" value="firstPage"/> </actions> <widgets> <decorator-screen name="main-decorator" location="component://crm/widget/crmmgr/CommonScreens.xml"> <decorator-section name="body"> <platform-specific><html><html-template location="component://crm/webapp/crmmgr/crm/firstPage.ftl"/></html></pla tform-specific> </decorator-section> </decorator-screen> </widgets> </section> </screen> So, when I'm requesting this page thru OFbiz request: https://localhost:8443/crmmgr/control/main I get the following error: Error in request handler: Exception: org.ofbiz.webapp.control.RequestHandlerException Message: Unknown request [org]; this request does not exist or cannot be called directly. And If I changed the org.ofbiz.webapp.applet.EmbeddedViewerApplet to EmbeddedViewerApplet after removing the package name and change the directory of EmbeddedViewerApplet I get rror in request handler: Exception: org.ofbiz.webapp.control.RequestHandlerException Message: Unknown request [EmbeddedViewerApplet.class]; this request does not exist or cannot be called directly. Can anyone help me please Thanks, ================================== Mamdouh Kaadan Software Engineer IT - Application Areeba SYRIA Mobile: +963-94-222763 Office : +963-94-222222 Ext: 2288 E-mail:[hidden email] |
calling applets and code base has to be URL.
you can do a search for applet in the source code for examples. Mahmoud's Kaadan sent the following on 10/18/2006 7:04 AM: > Dear all, > > I'm trying to run applet into one of my OFBiz pages, I included ftl file > (I had replcaed all path for absolute for a while): > > <!--"CONVERTED_APPLET"--> > > <!-- HTML CONVERTER --> > > <SCRIPT LANGUAGE="JavaScript"><!-- > > var _info = navigator.userAgent; > > var _ns = false; > > var _ns6 = false; > > var _ie = (_info.indexOf("MSIE") > 0 && _info.indexOf("Win") > 0 && > _info.indexOf("Windows 3.1") < 0); > > //--></SCRIPT> > > <COMMENT> > > <SCRIPT LANGUAGE="JavaScript1.1"><!-- > > var _ns = (navigator.appName.indexOf("Netscape") >= 0 && > ((_info.indexOf("Win") > 0 && _info.indexOf("Win16") < 0 && > java.lang.System.getProperty("os.version").indexOf("3.5") < 0) || > (_info.indexOf("Sun") > 0) || (_info.indexOf("Linux") > 0) || > (_info.indexOf("AIX") > 0) || (_info.indexOf("OS/2") > 0))); > > var _ns6 = ((_ns == true) && (_info.indexOf("Mozilla/5") >= 0)); > > //--></SCRIPT> > > </COMMENT> > > > > <SCRIPT LANGUAGE="JavaScript"><!-- > > if (_ie == true) document.writeln('<OBJECT > classid="clsid:8AD9C840-044E-11D1-B3E9-00805F499D93" WIDTH = "600" > HEIGHT = "400" > codebase="http://java.sun.com/products/plugin/1.1.2/jinstall-112-win32.c > ab#Version=1,1,2,0"><NOEMBED><XMP>'); > > else if (_ns == true && _ns6 == false) document.writeln('<EMBED > type="application/x-java-applet;version=1.1.2" CODE = > "org.ofbiz.webapp.applet.EmbeddedViewerApplet" CODEBASE = > "C:/workspace/ofbiz/framework/webapp/build/lib" ARCHIVE = > "jasperreports-0.6.0-applet.jar" WIDTH = "600" HEIGHT = "400" REPORT_URL > = "/testReport" scriptable=false > pluginspage="http://java.sun.com/products/plugin/1.1.2/plugin-install.ht > ml"><NOEMBED><XMP>'); > > //--></SCRIPT> > > <APPLET CODE = "org.ofbiz.webapp.applet.EmbeddedViewerApplet" CODEBASE > = "C:/workspace/ofbiz/framework/webapp/build/lib" ARCHIVE = > "jasperreports-0.6.0-applet.jar,ofbiz-webapp.jar" WIDTH = "600" HEIGHT = > "400"></XMP> > > <PARAM NAME = CODE VALUE = > "org.ofbiz.webapp.applet.EmbeddedViewerApplet" > > > <PARAM NAME = CODEBASE VALUE = > "C:/workspace/ofbiz/framework/webapp/build/lib" > > > <PARAM NAME = ARCHIVE VALUE = > "jasperreports-0.6.0-applet.jar,ofbiz-webapp.jar" > > > <PARAM NAME="type" VALUE="application/x-java-applet;version=1.2.2"> > > <PARAM NAME="scriptable" VALUE="false"> > > <PARAM NAME = "REPORT_URL" VALUE ="/testReport"> > > > > > > </APPLET> > > </NOEMBED> > > </EMBED> > > </OBJECT> > > <!--"END_CONVERTED_APPLET"--> > > > > > > For the controller > > <request-map uri="main"> > > <security https="true" auth="true"/> > > <response name="success" type="view" value="main"/> > > </request-map> > > > > > > And the screen is > > > > <screen name="Main"> > > <section> > > <actions> > > <set field="title" value="Main Page"/> > > <set field="titleProperty" value="MainPage"/> > > <set field="headerItem" value="firstPage"/> > > </actions> > > <widgets> > > <decorator-screen name="main-decorator" > location="component://crm/widget/crmmgr/CommonScreens.xml"> > > <decorator-section name="body"> > > <platform-specific><html><html-template > location="component://crm/webapp/crmmgr/crm/firstPage.ftl"/></html></pla > tform-specific> > > </decorator-section> > > </decorator-screen> > > </widgets> > > </section> > > </screen> > > > > So, when I'm requesting this page thru OFbiz request: > https://localhost:8443/crmmgr/control/main > I get the following error: > > > > Error in request handler: > > Exception: org.ofbiz.webapp.control.RequestHandlerException > > Message: Unknown request [org]; this request does not exist or cannot be > called directly. > > > > And If I changed the org.ofbiz.webapp.applet.EmbeddedViewerApplet to > EmbeddedViewerApplet > > after removing the package name and change the directory of > EmbeddedViewerApplet > > I get > > rror in request handler: > > Exception: org.ofbiz.webapp.control.RequestHandlerException > > Message: Unknown request [EmbeddedViewerApplet.class]; this request does > not exist or cannot be called directly. > > > > Can anyone help me please > > > Thanks, > > > > > > > > > > ================================== > > Mamdouh Kaadan > > Software Engineer > > IT - Application > > Areeba SYRIA > > Mobile: +963-94-222763 > > Office : +963-94-222222 Ext: 2288 > > E-mail:[hidden email] > > > > > > |
Free forum by Nabble | Edit this page |