0 Replies Latest reply on Mar 8, 2007 8:57 AM by DanteEC

    JSP and Flex: Reference external MXML

    DanteEC
      Hi, i have an issue that i'm hoping someone can help me with. I am attempting to insert a flex app into a jsp by referencing an external MXML file. I am getting a null pointer exception returned from jboss every time.

      I believe that i have all the proper tablib's and other JARS in the proper location. When i inline my MXML the flex app displays perfectly. If i change the exact same MXML from an inline, to an external reference, the application blows up.

      Here is the problematic JSP:

      <?xml version="1.0" encoding="UTF-8"?>
      <jsp:root version="1.2" xmlns:jsp=" http://java.sun.com/JSP/Page" xmlns:mm="FlexTagLib">
      <jsp:directive.page contentType="text/html;charset=UTF-8" pageEncoding="UTF-8" />

      <mm:mxml source="helloworld.mxml"></mm:mxml>
      </jsp:root>

      And here is the null pointer exception:

      java.lang.NullPointerException
      flex2.server.j2ee.jsp.MxmlTagImpl.setupExternalCompileMxmlContext(MxmlTagImpl.java:566)
      flex2.server.j2ee.jsp.MxmlTagImpl.compileExternal(MxmlTagImpl.java:423)
      flex2.server.j2ee.jsp.MxmlTagImpl.doEndTag(MxmlTagImpl.java:339)
      flex.bootstrap.BootstrapTag.doEndTag(BootstrapTag.java:62)
      org.apache.jsp.index_jsp._jspx_meth_mm_mxml_0(org.apache.jsp.index_jsp:76)
      org.apache.jsp.index_jsp._jspService(org.apache.jsp.index_jsp:52)
      org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:97)
      javax.servlet.http.HttpServlet.service(HttpServlet.java:810)
      org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:322)
      org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:314)
      org.apache.jasper.servlet.JspServlet.service(JspServlet.java:264)
      javax.servlet.http.HttpServlet.service(HttpServlet.java:810)
      org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:81)

      Thanks!