No newlines in DOM serialization

Hi,
I want to serialize a Document object to XML using the following code:
OutputFormat format = new OutputFormat(xhtmlDoc);
format.setIndenting(true);
format.setPreserveSpace(true);
format.setLineSeparator(System.getProperty("line.separator"));
format.setMethod("text/xhtml");
XMLSerializer serial = new XMLSerializer(new BufferedWriter(res.getWriter()), format);
DOMSerializer domserial = serial.asDOMSerializer();
domserial.serialize(xhtmlDoc);
res is a HttpServletResponse object. The serialized XML is submitted to the client and should be pretty printed. What I get is the complete serialize output on a single line.
I'm using Sun's fork of Xerces (embedded in JDK).
What do I have to do?
Thanks!
-Felix

This is just a wild guess, but have you tried
format.setMethod("text/xml"); instead? I have the feeling that XHTML isn't supposed to be indented.

Similar Messages

  • Serialization of DOM Tree+calling POST method in servlet

    Hi all,
    I am trying to serialize a DOM tree and send it from an applet to a servlet..I am having difficulty in calling the post method of the servlet..can anyone please tell me how the POST method in the servlet is called from the applet...I am using the code as seen on the forum for calling the POST method as below:
    URL url = new URL("http://localhost:8080/3awebapp/updateservlet");
    HttpURLConnection con = (HttpURLConnection)url.openConnection();
    con.setUseCaches(false);
    con.setRequestProperty("Content-Type","application/octet-stream");
    System.out.println("Connected");
    con.setDoOutput(true);
    con.setRequestMethod("POST");
    System.out.println("do output called");
    con.setDoInput(true);
    System.out.println("do Input called");
    ObjectOutputStream objout = new ObjectOutputStream(con.getOutputStream());
    yet the post method in the servlet does not seem to be called....
    another problem I had was trying to serialize a DOM document and send it to the servlet. I am using the following code to write the DOM document on an output stream..would this work:
    OutputFormat format = new OutputFormat(document);
    XMLSerializer serializer = new XMLSerializer( objout, format );
    System.out.println("XML Serializer Started");
    DOMSerializer newSerializer=serializer.asDOMSerializer();
    newSerializer.serialize( document );
    objout.flush();
    objout.close();
    ...since the doPost method of the servlet is not being called I do not whether the above code would be sent to the servlet..
    Any advice on the above two matters would be highly appreciated..
    Fenil

    perhaps my piece of code may help You - relevant parts marked //<--,
    but I have a problem when reading my object - which is a serialized DomTree :
    Variant 1 : sending XML-data as string will arrive as should be, but parser says org.xml.sax.SAXParseException (missing root-element)
    Variant 2 : readObject says java.io.OptionalDataException, but the DomTree will be parsed and displayed
    -- snipp --
    import java.io.InputStream;
    import org.w3c.dom.Document;
    import java.net.*;
    import com.oreilly.servlet.HttpMessage; //<--
    import java.util.*;
    import java.io.ObjectInputStream;
    myApplet :
    try {
         URL url = new URL(getCodeBase(),"../../xml/FetchDocument");
         HttpMessage msg = new HttpMessage(url);
         Properties props = new Properties();
         props.put("InputFeldName","FeldWert");
         InputStream in = msg.sendGetMessage(props);
    //<-- alt : sendPostMessage
         ObjectInputStream result = new ObjectInputStream(in);
         try {
         Object obj = result.readObject();
    myServlet :
    public void doGet(HttpServletRequest req,HttpServletResponse res)
         throws ServletException, IOException {
    TreeCreator currentTree = new TreeCreator();
    ObjectOutputStream out = new ObjectOutputStream(res.getOutputStream());
    -- variant 1 :
    out.writeObject(currentTree.skillOutputString());
    out.flush();
    out.close();
    -- variant 2 :          
    OutputFormat( TreeCreator.cdi ); //Serialize DOM
    OutputFormat format = new OutputFormat( currentTree.getCDI() ); format.setEncoding("ISO-8859-1");
    XMLSerializer serial = new XMLSerializer( out, format );
    serial.asDOMSerializer(); // As a DOM Serializer
    serial.serialize( currentTree.getCDI().getDocumentElement() );
    serial.endDocument();
    out.flush();
    out.close();

  • Serialization giving probem with HashMap

    Hi,
    I am creating a new document and could serialize it without fail.
    But if I add the created document to the HashMap. and then get the document from hashMap and try to serialize, OutputFormat throws NullPointerException,
    Here's the exception message---
    java.lang.NullPointerException
            at org.apache.xml.serialize.OutputFormat.whichMethod(Unknown Source)
            at org.apache.xml.serialize.OutputFormat.<init>(Unknown Source)*/
    Here's the code I am using--->
    HashMap documentsMap = new HashMap();
    Document doc= new DocumentImpl();
    Element root = doc.createElement("person");     // Create Root Element
    Element item = doc.createElement("name");       // Create element
    item.appendChild( doc.createTextNode("Jeff") );
    root.appendChild( item );       // Attach another Element - 
    doc.appendChild( root );        // Add Root to Document
    //add to the HashMap....
    documentsMap.put("node1",doc );
      try
       Iterator iterator = documentsMap.entrySet().iterator();
       while (iterator.hasNext() )
          Object key = iterator.next();
          doc= (Document)taxonomyNodesMap.get(key);
          OutputFormat format  = new OutputFormat( doc );   //Serialize DOM
          StringWriter  stringOut = new StringWriter();        //Writer will be a  
         XMLSerializer    serial = new XMLSerializer( stringOut, format );
        serial.asDOMSerializer();                            // As a DOM Serializer
        serial.serialize( doc.getDocumentElement());
      }catch......
    Any help will be greatly appreciated..
    Regards,
    Peter

    You have to use
    Iterator iterator = documentsMap.keySet().iterator();to get an iterator over all KEYS in your Hashmap.
    Cheers,
    Torsten

  • Writer a DOM to a File

    Hi guys, I need some help.
    I just try to writer a DOM to a xml document. The DOM API don't hava a "marshall" method to do this?!!? I don't find a method to write a DOM into a xml document at the Java2sdk API.
    Thanks.
    Giscard.

    You can org.apache.xml.serialize.XMLSerializer Class provided by xerces to write DOM in the file. Create XMLSerializer class object
              OutputFormat format = new OutputFormat();
              XMLSerializer x = new XMLSerializer(stream,format); // provide the stream
              DOMSerializer dom = x.asDOMSerializer();
              dom.serialize(node); /// save the node
    Hope this will help you.
    Gurpreet

  • Heap space error while creating XML document from Resultset

    I am getting Heap space error while creating XML document from Resultset.
    It was working fine from small result set object but when the size of resultset was more than 25,000, heap space error
    I am already using -Xms32m -Xmx1024m
    Is there a way to directly write to xml file from resultset instead of creating the whole document first and then writing it to file? Code examples please?
    here is my code:
    stmt = conn.prepareStatement(sql);
    result = stmt.executeQuery();
    result.setFetchSize(999);
    Document doc = JDBCUtil.toDocument(result, Application.BANK_ID, interfaceType, Application.VERSION);
    JDBCUtil.write(doc, fileName);
    public static Document toDocument(ResultSet rs, String bankId, String interfaceFileType, String version)
        throws ParserConfigurationException, SQLException {
            DocumentBuilderFactory factory = DocumentBuilderFactory.newInstance();
            DocumentBuilder builder = factory.newDocumentBuilder();
            Document doc = builder.newDocument();
            Element results = doc.createElement("sims");
            results.setAttribute("bank", bankId);
            results.setAttribute("record_type", "HEADER");
            results.setAttribute("file_type", interfaceFileType);
            results.setAttribute("version", version);
            doc.appendChild(results);
            ResultSetMetaData rsmd = rs.getMetaData();
            int colCount = rsmd.getColumnCount();
            String columnName="";
            Object value;
            while (rs.next()) {
                Element row = doc.createElement("rec");
                results.appendChild(row);
                for (int i = 1; i <= colCount; i++) {
                    columnName = rsmd.getColumnLabel(i);
                    value = rs.getObject(i);
                    Element node = doc.createElement(columnName);
                    if(value != null)
                        node.appendChild(doc.createTextNode(value.toString()));
                    else
                        node.appendChild(doc.createTextNode(""));
                    row.appendChild(node);
            return doc;
    public static void write(Document document, String filename) {
            //long start = System.currentTimeMillis();
            // lets write to a file
            OutputFormat format = new OutputFormat(document); // Serialize DOM
            format.setIndent(2);
            format.setLineSeparator(System.getProperty("line.separator"));
            format.setLineWidth(80);
            try {
                FileWriter writer = new FileWriter(filename);
                BufferedWriter buf = new BufferedWriter(writer);
                XMLSerializer FileSerial = new XMLSerializer(writer, format);
                FileSerial.asDOMSerializer(); // As a DOM Serializer
                FileSerial.serialize(document);
                writer.close();
            } catch (IOException ioe) {
                ioe.printStackTrace();
            //long end = System.currentTimeMillis();
            //System.err.println("W3C File write time :" + (end - start) + "  " + filename);
        }

    you can increase your heap size..... try setting this as your environment variable.....
    variable: JAVA_OPTS
    value: -Xms512m -Xmx1024m -XX:PermSize=256m -XX:MaxPermSize=512m

  • Wsd services

    <?xml version="1.0" encoding="UTF-8"?>
    <configuration xmlns="http://java.sun.com/xml/ns/jax-rpc/ri/config">
    <wsdl
    location="AvalonWebService.wsdl"
    packageName="com.package.stubs "/>
    </configuration>
    C:\jwsdp-2.0\jaxrpc\bin\wscompile.bat -gen:client -keep -verbose -classpath build config.xml
    import javax.xml.rpc.Stub;
    import com.package.stubs.AnnwynServicePortType;
    import com.package.stubs.AnnwynService_Impl;
    import com.package.stubs.ProcessResponseSync;
    public class Ws
         public String getResponsePayload(String username,String password,String headerXML,String payloadXML,String path)
              String p="";
              try
                   AnnwynServicePortType port=null;
                   ProcessResponseSync res=null;
                   String endpointAddress = path+"/biocap/ws/AnnwynServicePort/AnnwynServicePort";
                   try
                        javax.xml.rpc.Stub stub = (Stub) (new AnnwynService_Impl().getAnnwynServicePort());
                        stub._setProperty(javax.xml.rpc.Stub.ENDPOINT_ADDRESS_PROPERTY,endpointAddress);
                        port = (AnnwynServicePortType)stub;
                        stub._setProperty(Stub.USERNAME_PROPERTY,username);
                        stub._setProperty(Stub.PASSWORD_PROPERTY,password);                
                   catch(Exception ex)
                        System.out.println("Authentication error in Ws.java : "+ex.toString());
                   res=port.processSync(headerXML,payloadXML);
                   p=res.getPayloadXML();
              catch(Exception e)
    System.out.println("Error in Ws.java : "+e.toString());          
              return p;
    --------------------------------------for parsing xml file------------------------------------------------
    import java.io.*;
    import java.util.ArrayList;
    import java.util.Iterator;
    import java.util.List;
    import javax.xml.parsers.DocumentBuilder;
    import javax.xml.parsers.DocumentBuilderFactory;
    import javax.xml.parsers.ParserConfigurationException;
    import org.w3c.dom.Document;
    import org.w3c.dom.Element;
    import org.w3c.dom.NodeList;
    import org.w3c.dom.Node;
    import org.xml.sax.SAXException;
    import java.util.Hashtable;
    public class XMLParse
         Document dom;
         NodeList nl;
         Hashtable countries=new Hashtable();
         //int key=0;
         public Hashtable getNames(String payloadXML,String attrib,String id)
    //public Hashtable getNames(byte bb[])
              try
                   DocumentBuilderFactory dbf = DocumentBuilderFactory.newInstance();
                   DocumentBuilder db = dbf.newDocumentBuilder();
                   byte bb[]=payloadXML.getBytes();
                   //java.io.ByteArrayInputStream bais=new java.io.ByteArrayInputStream(bb);               
    java.io.InputStream is=new java.io.ByteArrayInputStream(bb);               
                   dom = db.parse(is);                              
                   Element docEle = dom.getDocumentElement();
                   nl=docEle.getElementsByTagName("Messages");
                   for ( int k = 0; k <nl.getLength(); k++ )
                        NodeList childNodeList = nl.item(k).getChildNodes();
                        for(int i=0;i<(childNodeList.getLength())-1;i++)
                             i=i+1;
                             Node childNode = childNodeList.item(i);     
                             String CountryName=((Element)childNodeList.item(i)).getAttribute(attrib);
                             String idValue=((Element)childNodeList.item(i)).getAttribute(id);
                             countries.put(idValue,CountryName);
                             //key++;
              catch(Exception e)
              {System.out.println("Exception in initParser:------>"+e);}
              return countries;
    // public static void main(String args[]) throws Exception
    // try
    // FileInputStream fis=new FileInputStream("D:/Jagadeesan/Jagadeesan_Examples/JavaApplication6/src/parser/out.xml");
    // int length=fis.available();
    // byte b[]=new byte[length];
    // int len;
    // while((len=fis.read(b)) >= 0)
    // Hashtable h=new XMLParse().getNames(b);
    // System.out.println("----Countries----\n");
    // for(int i=0;i<h.size();i++)
    // System.out.println(" "+h.get(new Integer(i)));
    // System.out.println("\n-----------------");
    // catch(Exception e)
    // e.printStackTrace();
    ----------------------------for creating xml fie------------------------------------------------
    import org.w3c.dom.*;
    import org.apache.xerces.dom.DocumentImpl;
    import org.apache.xerces.dom.DOMImplementationImpl;
    import org.apache.xml.serialize.OutputFormat;
    import org.apache.xml.serialize.Serializer;
    import org.apache.xml.serialize.SerializerFactory;
    import org.apache.xml.serialize.XMLSerializer;
    import java.io.*;
    import org.w3c.dom.Attr;
    import org.w3c.dom.CDATASection;
    import org.w3c.dom.Comment;
    import org.w3c.dom.Document;
    import org.w3c.dom.Element;
    import org.w3c.dom.Node;
    import org.w3c.dom.ProcessingInstruction;
    import java.util.*;
    public class payloadXML
         public String getpayloadXML(Hashtable request_HT) throws Exception
              Document document= new DocumentImpl();
              Element root = document.createElement("Root");     
              // add child element
              Node Messages_Node = create_Messages_Node(document,request_HT);
              root.appendChild(Messages_Node);
              // create attribute
              Attr xmlns_xsd_Attribute = document.createAttribute("xmlns:xsd");
              xmlns_xsd_Attribute.setValue("http://www.w3.org/2001/XMLSchema");
              // append attribute to root element
              root.setAttributeNode(xmlns_xsd_Attribute);
              // create attribute
              Attr xmlns_xsi_Attribute = document.createAttribute("xmlns:xsi");
              xmlns_xsi_Attribute.setValue("http://www.w3.org/2001/XMLSchema-instance");
              // append attribute to root element
              root.setAttributeNode(xmlns_xsi_Attribute);
              // create attribute
              Attr localizationId_Attribute = document.createAttribute("localizationId");
              localizationId_Attribute.setValue("en-GB");
              // append attribute to root element
              root.setAttributeNode(localizationId_Attribute);
              // create attribute
              Attr xmlns_Attribute = document.createAttribute("xmlns");
              xmlns_Attribute.setValue("http://www.avalonbiometrics.com/biocap/Messages");
              // append attribute to root element
              root.setAttributeNode(xmlns_Attribute);
    document.appendChild( root );
    OutputFormat format = new OutputFormat( document ); //Serialize DOM
              StringWriter stringOut = new StringWriter(); //Writer will be a String
              XMLSerializer serial = new XMLSerializer( stringOut, format );
              serial.asDOMSerializer(); // As a DOM Serializer
              serial.serialize( document.getDocumentElement() );
              //System.out.println( "STRXML = " + stringOut.toString()); //Spit out DOM as a String
              return stringOut.toString();           
         public Node create_Messages_Node(Document document,Hashtable request_HT)
    // create Msg:Messages element
    Element Messages = document.createElement("Messages");
    for(Enumeration key = request_HT.keys(); key.hasMoreElements();)
    Object keyName=key.nextElement();
    // create attribute
    Attr Attribute_Name = document.createAttribute(keyName.toString());
    Attribute_Name.setValue((request_HT.get(keyName).toString()));
    // append attribute to Msg:Messages element
    Messages.setAttributeNode(Attribute_Name);
    return Messages;
    ----------------------for xml parsing---------------------------------------
    import java.io.*;
    import java.util.ArrayList;
    import java.util.Iterator;
    import java.util.List;
    import javax.xml.parsers.DocumentBuilder;
    import javax.xml.parsers.DocumentBuilderFactory;
    import javax.xml.parsers.ParserConfigurationException;
    import org.w3c.dom.Document;
    import org.w3c.dom.Element;
    import org.w3c.dom.NodeList;
    import org.w3c.dom.Node;
    import org.xml.sax.SAXException;
    import java.util.Hashtable;
    public class XMLParseSeqNo
         Document dom;
         NodeList nl;
         String seqNumber="";
         public String getNames(String payloadXML)
              try
                   DocumentBuilderFactory dbf = DocumentBuilderFactory.newInstance();
                   DocumentBuilder db = dbf.newDocumentBuilder();
                   byte bb[]=payloadXML.getBytes();               
    java.io.InputStream is=new java.io.ByteArrayInputStream(bb);               
                   dom = db.parse(is);                              
                   Element docEle = dom.getDocumentElement();
                   nl=docEle.getElementsByTagName("Messages");
                   for ( int k = 0; k <nl.getLength(); k++ )
                   Element el = (Element)nl.item(k);
    seqNumber= el.getAttribute("seqNumber");
    catch(Exception e)
    System.out.println("Exception in initParser:------>"+e);
              return seqNumber;
    }

    null

  • Xml payload in a single field

    Hi All,
    I hve a scenario like this ERP->XI->Monitoring system
    In the mapping, I need to assign the outbound payload (whole xml) to a field in the target
    message field since the (Target) Monitoring system wants to receive the whole xml message in single field.
    How can i achieve this?
    Thanks
    Deno

    try this.. some of the imports are not required.. however I just copied from my code..
    import javax.ejb.CreateException;
    import javax.ejb.SessionBean;
    import javax.ejb.SessionContext;
    import com.sap.aii.af.mp.module.Module;
    import com.sap.aii.af.mp.module.ModuleContext;
    import com.sap.aii.af.mp.module.ModuleData;
    import com.sap.aii.af.mp.module.ModuleException;
    import com.sap.aii.af.ra.ms.api.Message;
    import com.sap.aii.af.service.trace.Trace;
    import java.util.Hashtable;
    //XML Parsing and Transformation classes
    import javax.xml.parsers.*;
    import org.w3c.dom.*;
    import java.io.InputStream;
    import java.io.ByteArrayOutputStream;
    import java.io.StringWriter;
    import com.sap.aii.af.ra.ms.api.XMLPayload;
    import com.sun.org.apache.xml.internal.serialize.OutputFormat;
    import com.sun.org.apache.xml.internal.serialize.XMLSerializer;
    import javax.xml.transform.*;
    import javax.xml.transform.Source;
    import javax.xml.transform.Result;
    import javax.xml.transform.dom.DOMSource;
    import javax.xml.transform.stream.StreamResult;     
    Object obj = null; //Handler to get principal data
              Message msg = null;// Handler to get message object
              String getXMLtoField = null;
              try {
                   obj = inputModuleData.getPrincipalData();
                   msg = (Message)obj;
                   XMLPayload xmlpayload = msg.getDocument();
                        DocumentBuilderFactory factory;
                        factory =DocumentBuilderFactory.newInstance();
                        DocumentBuilder builder = factory.newDocumentBuilder();
                        // parse the XML Payload
                        Document document = builder.parse((InputStream)
                        xmlpayload.getInputStream());
                        OutputFormat format = new OutputFormat(document);    // Serialize DOM
                        StringWriter stringOut = new StringWriter();    // Writer will be a String
                        XMLSerializer serial = new XMLSerializer(stringOut, format);
                        serial.asDOMSerializer();                       // As a DOM Serializer
                        serial.serialize(document.getDocumentElement());
                        String FileContent = stringOut.toString();
              return getXMLtoField;

  • A class to format an XML string into indented xml code

    I am looking for a class or a piece of code to format an XML string into indented xml code
    for example: an XML string as follows
    <servlet><servlet-name>Login</servlet-name>servlet-class>ucs.merch.client.system.LoginServlet</servlet-class></servlet><servlet-mapping><servlet-name>Login</servlet-name>
    to format into :
    <servlet>
    <servlet-name>Login</servlet-name>
    <servlet-class>ucs.merch.client.system.LoginServlet</servlet-class>
    </servlet>
    <servlet-mapping>
    <servlet-name>Login</servlet-name>
    <url-pattern>/Login</url-pattern>
    </servlet-mapping>
    e-mail : [email protected]

    Xerces has a class called OutputFormat
    If you have your XML document in memory, you can format it using the method setIndenting(true) on the OutputFormat class. The following is an example:
    assuming xmlDoc is our document and fileName is the name of the file we wish to write to:
    OutputFormat format = new OutputFormat(xmlDoc);
    // setup output file name
    PrintWriter printwriter = new PrintWriter(new FileWriter(fileName, false));
    // construct an XMLSerializer for writing the document
    XMLSerializer serializer = new XMLSerializer( printwriter, format );
    // Ensure output is indented correctly...
    format.setIndenting(true);
    // set serializer as a DOM Serializer
    serializer.asDOMSerializer();
    // serialize the document
    serializer.serialize(xmlDoc);
    hope this helps!
    Rob.

  • OS X 10.4 (PPC or Intel) - opening project issues

    I readed some posts on startup problems but it seemed that, first, I got all of them at the same time, second, no one of these posts solved my issues.
         i) If I create a new project I receive that exception:
    java.io.IOException: Could not find a safe DOM serializer: java.lang.NoSuchMethodException: org.apache.xml.serialize.XMLSerializer.setNamespaces(boolean)
    at org.openide.xml.XMLUtilImpl.write(XMLUtilImpl.java:72)
    at org.openide.xml.XMLUtil.write(XMLUtil.java:298)
    at org.netbeans.spi.project.support.ant.ProjectGenerator$1.run(ProjectGenerator.java:103)
    at org.openide.util.Mutex.writeAccess(Mutex.java:310)
    at org.netbeans.spi.project.support.ant.ProjectGenerator.createProject0(ProjectGenerator.java:78)
    at org.netbeans.spi.project.support.ant.ProjectGenerator.createProject(ProjectGenerator.java:73)
    at org.netbeans.modules.web.project.WebProjectGenerator.setupProject(WebProjectGenerator.java:354)
    at org.netbeans.modules.web.project.WebProjectGenerator.createProject(WebProjectGenerator.java:112)
    at com.sun.rave.jsf.project.services.WebProjectCreatorImpl.createProject(WebProjectCreatorImpl.java:37)
    at com.sun.rave.api.jsf.project.JsfProjectHelper.createWebProject(JsfProjectHelper.java:729)
    at com.sun.rave.api.jsf.project.ui.wizards.NewJsfProjectWizardIterator.instantiate(NewJsfProjectWizardIterator.java:77)
    at org.openide.loaders.TemplateWizard$Brigde2Iterator.instantiate(TemplateWizard.java:969)
    at org.openide.loaders.TemplateWizard.handleInstantiate(TemplateWizard.java:557)
    at org.openide.loaders.TemplateWizard.instantiateNewObjects(TemplateWizard.java:396)
    at org.openide.loaders.TemplateWizardIterImpl.instantiate(TemplateWizardIterImpl.java:218)
    at org.openide.WizardDescriptor.callInstantiate(WizardDescriptor.java:1425)
    at org.openide.WizardDescriptor.access$900(WizardDescriptor.java:63)
    at org.openide.WizardDescriptor$Listener.actionPerformed(WizardDescriptor.java:1327)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
    at java.lang.reflect.Method.invoke(Method.java:585)
    at org.openide.util.WeakListenerImpl$ProxyListener.invoke(WeakListenerImpl.java:383)
    at $Proxy15.actionPerformed(Unknown Source)
    at javax.swing.AbstractButton.fireActionPerformed(AbstractButton.java:1882)
    at javax.swing.AbstractButton$Handler.actionPerformed(AbstractButton.java:2202)
    at javax.swing.DefaultButtonModel.fireActionPerformed(DefaultButtonModel.java:420)
    at javax.swing.DefaultButtonModel.setPressed(DefaultButtonModel.java:258)
    at javax.swing.plaf.basic.BasicButtonListener.mouseReleased(BasicButtonListener.java:234)
    at java.awt.Component.processMouseEvent(Component.java:5554)
    at javax.swing.JComponent.processMouseEvent(JComponent.java:3126)
    at java.awt.Component.processEvent(Component.java:5319)
    at java.awt.Container.processEvent(Container.java:2010)
    at java.awt.Component.dispatchEventImpl(Component.java:4021)
    at java.awt.Container.dispatchEventImpl(Container.java:2068)
    at java.awt.Component.dispatchEvent(Component.java:3869)
    at java.awt.LightweightDispatcher.retargetMouseEvent(Container.java:4256)
    at java.awt.LightweightDispatcher.processMouseEvent(Container.java:3936)
    at java.awt.LightweightDispatcher.dispatchEvent(Container.java:3866)
    at java.awt.Container.dispatchEventImpl(Container.java:2054)
    at java.awt.Window.dispatchEventImpl(Window.java:1774)
    at java.awt.Component.dispatchEvent(Component.java:3869)
    at java.awt.EventQueue.dispatchEvent(EventQueue.java:463)
    at java.awt.EventDispatchThread.pumpOneEventForHierarchy(EventDispatchThread.java:269)
    at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:190)
    at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:184)
    at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:176)
    at java.awt.EventDispatchThread.run(EventDispatchThread.java:110)
    Caused by: java.lang.NoSuchMethodException: org.apache.xml.serialize.XMLSerializer.setNamespaces(boolean)
         ii) When I open an already existing jsp page in a project I receive from the designer:
    java.lang.ClassCastException: org.apache.xerces.dom.DeferredDocumentImpl
         at com.sun.rave.insync.markup.MarkupUnit.syncEngine(MarkupUnit.java:488)
         at com.sun.rave.insync.markup.MarkupUnit.read(MarkupUnit.java:451)
         at com.sun.rave.insync.SourceUnit.sync(SourceUnit.java:446)
         at com.sun.rave.insync.faces.FacesPageUnit.syncSubUnits(FacesPageUnit.java:223)
         at com.sun.rave.insync.beans.BeansUnit.sync(BeansUnit.java:174)
         at com.sun.rave.insync.live.LiveUnit.sync(LiveUnit.java:288)
         at com.sun.rave.insync.live.LiveUnitWrapper.sync(LiveUnitWrapper.java:115)
         at com.sun.rave.insync.models.FacesModel.syncImpl(FacesModel.java:899)
         at com.sun.rave.insync.Model.sync(Model.java:207)
         at com.sun.rave.insync.Model.sync(Model.java:173)
         at com.sun.rave.insync.ModelSet$WindowManagerPropertyRegistry.processNodes(ModelSet.java:107)
         at com.sun.rave.insync.ModelSet$WindowManagerPropertyRegistry.propertyChange(ModelSet.java:125)
         at java.beans.PropertyChangeSupport.firePropertyChange(PropertyChangeSupport.java:333)
         at java.beans.PropertyChangeSupport.firePropertyChange(PropertyChangeSupport.java:270)
         at org.netbeans.core.windows.RegistryImpl.doFirePropertyChange(RegistryImpl.java:249)
         at org.netbeans.core.windows.RegistryImpl.tryFireChanges(RegistryImpl.java:222)
         at org.netbeans.core.windows.RegistryImpl.selectedNodesChanged(RegistryImpl.java:186)
         at org.netbeans.core.windows.RegistryImpl.topComponentActivated(RegistryImpl.java:138)
         at org.netbeans.core.windows.WindowManagerImpl.notifyRegistryTopComponentActivated(WindowManagerImpl.java:893)
         at org.netbeans.core.windows.Central.activateModeTopComponent(Central.java:1401)
         at org.netbeans.core.windows.WindowManagerImpl.topComponentRequestActive(WindowManagerImpl.java:994)
         at org.openide.windows.TopComponent.requestActive(TopComponent.java:553)
         at com.sun.rave.project.jsfloader.JsfJavaEditorSupport.doOpenDesigner(JsfJavaEditorSupport.java:130)
         at com.sun.rave.project.jsfloader.JsfJavaEditorSupport$1.run(JsfJavaEditorSupport.java:115)
         at org.openide.util.Mutex.doEvent(Mutex.java:1024)
         at org.openide.util.Mutex.writeAccess(Mutex.java:330)
         at com.sun.rave.project.jsfloader.JsfJavaEditorSupport.openDesigner(JsfJavaEditorSupport.java:113)
         at com.sun.rave.project.jsfloader.JsfJspEditorSupport.openDesigner(JsfJspEditorSupport.java:87)
         at com.sun.rave.project.jsfloader.JsfJspDataObject$OpenEdit.open(JsfJspDataObject.java:155)
         at org.openide.actions.OpenAction.performAction(OpenAction.java:54)
         at org.openide.util.actions.NodeAction$3.run(NodeAction.java:450)
         at org.openide.util.actions.CallableSystemAction.doPerformAction(CallableSystemAction.java:116)
         at org.openide.util.actions.NodeAction$DelegateAction.actionPerformed(NodeAction.java:448)
         at org.openide.explorer.view.TreeView$PopupSupport.mouseClicked(TreeView.java:1176)
         at java.awt.AWTEventMulticaster.mouseClicked(AWTEventMulticaster.java:212)
         at java.awt.AWTEventMulticaster.mouseClicked(AWTEventMulticaster.java:211)
         at java.awt.AWTEventMulticaster.mouseClicked(AWTEventMulticaster.java:211)
         at java.awt.Component.processMouseEvent(Component.java:5557)
         at javax.swing.JComponent.processMouseEvent(JComponent.java:3126)
         at java.awt.Component.processEvent(Component.java:5319)
    I tried all the JVM from Apple: 1.5 release 4 and 3, 1.4 too, I reinstalled many times the downloaded application "creator-2_1-mac-ml.command". Last but not least: It happened few month ago on an iMac PPC running 10.4.8, since that I worked on a Intel Core Duo box running 10.4.9 without any trouble.....until two days ago. I didn't updated JSC, nor modified directories, etc...

    Working around these issues, I note that within a newly created user account, jsc2 works well.
    Looking in the "~/Library" differences beetwen these two accounts, the defective account has a "/Java/Extensions" subfolder and a xerces.jar within. Such jar I believe to be the source of the problems. Putting in trash the /Java/ folder, jsc2 immediately work normally.

  • Java transform problem - resulting XML has wrong namespace on imported Node

    I use Document.importNode(Node, String) to import a node from one document into another document. I want to preserve the namespace of the imported node. This works ok if the imported node specifies xmlns, even xmlns="". But if the imported node does not specify a namespace, I would expect the resulting serialized XML to have xmlns="". However, this is not the case. I use javax.xml.transform.Transformer when I serialize the XML. After the transform, the imported node has the namespace of the document it is imported into, which we do not want. So how do I get the imported node to serialize out with xmlns="", even if it's not specified in the source document? I am using javax.xml.transform.* and javax.xml.parsers.DocumentBuilder from Java 1.4.2.
    Example of XML that node is imported into (imported node replaces PayloadPlaceHolder):
    <?xml version="1.0" encoding="UTF-8"?>
    <Envelope envelopeVersion="0.0.0" classificationLevel="Unclassified" xmlns="http://disa.gcss.mil/XMLGateway/Envelope">
    <Header>
    <UID>GM0000001</UID>
    <DateTime>2006-12-05T16:11:50Z</DateTime>
    </Header>
    <Status reason="FAILED" lastTransactionID="9999999999" inReplyTo="ZZZ9999999999">
    <LastMessageUID>ZZZ9999999999</LastMessageUID>
    </Status>
    <Payload>
    <PayloadPlaceHolder>
    </PayloadPlaceHolder>
    </Payload>]
    </Envelope>
    Example of XML with null namespace, test_segment is imported node:
    <?xml version="1.0" encoding="UTF-8"?>
    <test_segment>
    <name>test</name>
    </test_segment>
    Example of result XML with imported node (test_segment):
    <?xml version="1.0" encoding="UTF-8"?>
    <Envelope classificationLevel="Unclassified" envelopeVersion="0.0.0" xmlns="http://disa.gcss.mil/XMLGateway/Envelope">
    <Header>
    <UID>GM0000001</UID>
    <DateTime>2006-12-05T16:11:50Z</DateTime>
    </Header>
    <Status inReplyTo="ZZZ9999999999" lastTransactionID="9999999999" reason="FAILED">
    <LastMessageUID>ZZZ9999999999</LastMessageUID>
    </Status>
    <Payload>
    <test_segment>
    <name>test</name>
    </test_segment>
    </Payload>
    </Envelope>
    Here is the code to build the documents and transform the XML:
         Document document = null;
    Document dataBlockDoc = null;
    ByteArrayInputStream inStream = new ByteArrayInputStream
    (StringUtils.getBytes(xml.toString()));
    try {
    DocumentBuilderFactory dbf = DocumentBuilderFactory.newInstance();
    dbf.setNamespaceAware( true );
    DocumentBuilder parser = dbf.newDocumentBuilder();
    document =
    parser.parse(
    new InputSource(inStream ) );
    if (dataBlock != null) {
    inStream = new ByteArrayInputStream(StringUtils.getBytes(dataBlock));
    dataBlockDoc = parser.parse(
    new InputSource(inStream ) );
    Element root = document.getDocumentElement();
    Element payload = null;
    NodeList children = root.getChildNodes();
    //get Payload child from envelope document
    for (int i = 0; i < children.getLength(); i++) {
    if (children.item(i).getNodeName().equals("Payload")) {
    payload = (Element)children.item(i);
    break;
    //get the PayloadPlaceHolder
    Element payloadPlaceHolderElement = null;
    children = payload.getChildNodes();
    for (int i = 0; i < children.getLength(); i++) {
    if (children.item(i).getNodeName().equals("PayloadPlaceHolder")) {
    payloadPlaceHolderElement = (Element)children.item(i);
    break;
    Node newPayload = null;
    if (dataBlockDoc != null) {
    Element dataBlockElement = dataBlockDoc.getDocumentElement();
    //make new Payload element to replace old (empty) Payload
    newPayload = document.importNode((Node) dataBlockElement, true);
    payload.replaceChild(newPayload, payloadPlaceHolderElement);
    else
    payload.removeChild(payloadPlaceHolderElement);
    TransformerFactory tf = TransformerFactory.newInstance();
    Transformer nullTransform = tf.newTransformer();
    ByteArrayOutputStream oStream = new ByteArrayOutputStream();
    nullTransform.transform(                    new DOMSource( document ),
         new StreamResult( oStream ) );
    xml = new StringBuffer(oStream.toString());
    Thanks in advance.

    It appears that the problem is that the DOM serializer implementation in JDK 1.4 is not properly handling namespaces. Does anyone know of a workaround or alternate serializers we could use to serialize a DOM tree? I also need it to work with XSLT.
    Thanks.

  • Handle invalid xml character while serializing

    I have requirement where I need to serialize a document which contains a string like "ンᅧᅭ%ンᅨ &amp;". While serializing it throws the following exception
    java.io.IOException: The character ' ' is an invalid XML character
    Is there a way we can serialize this String as is with any workaround.
    StringWriter stringOut = new StringWriter();
      DocumentBuilderFactory docFactory = DocumentBuilderFactory.newInstance();
      DocumentBuilder docBuilder = docFactory.newDocumentBuilder();
      Document doc = docBuilder.newDocument();
      Element rootElement = doc.createElement("company");
      doc.appendChild(rootElement);
      String xml = "ンᅧᅭ%ンᅨ &amp;";
      //String xml = "ンᅧᅭ%ンᅨ &amp;";
      Element junk = doc.createElement("replyToQ");
      junk.appendChild(doc.createCDATASection(xml));
      //junk.appendChild(doc.createTextNode(stripNonValidXMLCharacters(xml)));
      rootElement.appendChild(junk);
      //org.w3c.dom.Document doc = this.toDOM();
      //Serialize DOM
      OutputFormat format = new OutputFormat(doc,"UTF-8",true);
      format.setIndenting(false);
      format.setLineSeparator("");
      format.setPreserveSpace(true);
      format.setOmitXMLDeclaration(false);
      XMLSerializer serial = new XMLSerializer( stringOut, format );
      // As a DOM Serializer
      serial.asDOMSerializer();
      serial.serialize( doc.getDocumentElement() );

    As a guess because you are treating CDATA as meaning the same as 'binary' which it isn't.  The characters in CDATA still must be valid XML characters.
    If you want binary data then base64 encode it and put that in the document - and you won't need CDATA at all then, it will just be regular element text.

  • Printing a Node

    Hello everyone:
    I am parsing an XML instance using xerces/w3cDOM, how do I print out a Node? I've looked around the API and only found a way of printing the whole document using getDocumentOwner and serializing it
    tempNode is a Node
    OutputFormat format = new OutputFormat( tempNode.getOwnerDocument(), "UTF-8", true ); /** Serialize DOM **/
    StringWriter stringOut = new StringWriter(); /** Writer will be a String **/
    XMLSerializer serial = new XMLSerializer( stringOut, format );
    try {
    serial.asDOMSerializer(); /** As a DOM Serializer **/
    serial.serialize( (tempNode.getOwnerDocument()).getDocumentElement());
    } catch (Exception exc){}
    System.out.println("Tree is:\n"+stringOut.toString());
    The above code prints out the whole document. How do I print tempNode?
    Thanks
    VP

    You can use a transformer.
    first import javax.xml.transform, set up an output stream (outStream) then:
        Transformer trans;
        TransformerFactory = transfac = TransformerFactory.newInstance();
        try{
          trans = transfac.newTransformer();
        catch(TransformerConfigurationException t){
          //do something
        catch(IllegalArgumentException i){
          //do something
        try{
          trans.transform(new DOMSource(tempNode), new StreamResult(outStream));
        catch(TransformerException t){
          //do something
        }If you want to print the Node to the screen just use System.out as your output stream. You can also store the text input in an array if you use a ByteArrayOutputStream.

  • Apache SOAP does not know how to serialize a DOM Element

    Hi all!
    I got a problem with the following:
    I created a webService with JDeveloper 9.0.3 . It has got two methods that are running as Service one void method which is updating a DB and another method which retruns a dom.w3c.org.Document.
    This all works fine as long as i try to run it within JDeveloper. After i deployed it to Apache Tomcat 4.1.13 only the void method works properly.
    When i try to run the method which returns a Document following error occurs:
    Call failed:
    Fault Code   = SOAP-ENV:Server
    Fault String = java.lang.IllegalArgumentException: No Serializer found to serialize a 'org.w3c.dom.Document' using encoding style 'http://schemas.xmlsoap.org/soap/encoding/'.
    [SOAPException: faultCode=SOAP-ENV:Server; msg=java.lang.IllegalArgumentException: No Serializer found to serialize a &apos;org.w3c.dom.Document&apos; using encoding style &apos;http://schemas.xmlsoap.org/soap/encoding/&apos;.]
    org.w3c.dom.Document gui.EmbeddedDbDBServiceStub.showDB()
    EmbeddedDbDBServiceStub.java:164Here is the code of the method.
      public Document showDB() throws Exception {
        Document returnVal = null;
        try {
          url = new URL("http://servername:7070/soap/servlet/rpcrouter");
        catch(Exception e){e.printStackTrace();}
        SOAPMappingRegistry registry = new SOAPMappingRegistry();
        BeanSerializer serializer = new BeanSerializer();
        registry.mapTypes(Constants.NS_URI_SOAP_ENC, new QName("urn:fhws11", "returnVal"), Document.class, serializer, serializer);
        Call call = new Call();
        call.setSOAPMappingRegistry(registry);
        call.setTargetObjectURI("urn:fhws11");
        call.setMethodName("showDB");
        call.setEncodingStyleURI(Constants.NS_URI_SOAP_ENC);
        Vector params = new Vector();
        call.setParams(params);
        Response response = call.invoke(url, "");
        if (!response.generatedFault()) {
          Parameter result = response.getReturnValue();
          returnVal = (Document)result.getValue();
        else {
          Fault fault = response.getFault();
          System.out.println("Call failed:");
          System.out.println("Fault Code   = " + fault.getFaultCode());
          System.out.println("Fault String = " + fault.getFaultString());
          throw new SOAPException(fault.getFaultCode(), fault.getFaultString());
        System.out.println(returnVal.getFirstChild().getNodeName());
        return returnVal;
      }I think there is an easy answer, but i am searching for several days now and don't know what to do else.
    Thx in Advance
    grufti

    Hi again!
    I have forgotten to post the original method code.
    public Document showDB() {
      Statement stmt = null;
      Connection con = null;
      ResultSet rs = null;
      Document result = null;
      Document doc= new DocumentImpl();
      try {
        this.getClass().forName("oracle.jdbc.driver.OracleDriver");
        con = DriverManager.getConnection("jdbc:oracle:thin:@xxx:1521:xxx", "usr", "pwd");
        stmt = con.createStatement();
      catch(SQLException ee) {
        ee.printStackTrace();
      catch(ClassNotFoundException clse) {
        clse.printStackTrace();
      // DBVerbindung aufgebaut, INSERT Statement absetzen
      try  {
        DocumentBuilderFactory factory = DocumentBuilderFactory.newInstance();
        DocumentBuilder builder = factory.newDocumentBuilder();
        doc = builder.newDocument();  // Create from whole cloth
        String selectString = "";
        selectString += "SELECT * from JWS_TEST";
        Element el = (Element)doc.createElement("JWS_TEST");
        rs = stmt.executeQuery(selectString);
        while(rs.next()) {
          Element row = (Element)doc.createElement("ROW");
          Element name = (Element)doc.createElement("NAME");
          Element strasse = (Element)doc.createElement("STRASSE");
          Element ort = (Element)doc.createElement("ORT");
          Element telefon = (Element)doc.createElement("TELEFON");
          name.appendChild( doc.createTextNode(rs.getString("name")));
          strasse.appendChild( doc.createTextNode(rs.getString("strasse")));
          ort.appendChild( doc.createTextNode(rs.getString("ort")));
          telefon.appendChild( doc.createTextNode(rs.getString("telefon")));
          row.appendChild(name);
          row.appendChild(strasse);
          row.appendChild(ort);
          row.appendChild(telefon);
          el.appendChild(row);
        doc.appendChild(el);
      catch(Exception ex)  {
        ex.printStackTrace();
      try {
        stmt.close();
        con.close();
        fw.close();
      catch(SQLException exx) {
        exx.printStackTrace();
      catch(Exception x) {
        x.printStackTrace();
      catch(IOException ioe) {ioe.printStackTrace();}
      return doc;
    }

  • Org.w3c.dom.Element Serialization

    I see in the serialization list that org.w3c.dom.Document get's serialized to XML, but is there a reason why org.w3c.dom.Element only get's serialized to an object?  I would think that it should also be serialized to an XML Object, is there a way to do this without having to implement custom serialization for the type?

    I found another way to do this using the BlazeDS BeanProxy.  Essentially when marshalling the object to Blaze I convert the Element to a String (could be a Dom if I chose, but String was sufficient) and on the way back I build it back out.
    http://bugs.adobe.com/jira/browse/BLZ-305 is the place I got the  details from.

  • No Serializer found to serialize a 'org.w3c.dom.Element' using encoding style ...

    I use oc4j903 and win2k. I write a document style web service following Demo for Stateless Java Document Web Services.
    I Create an EAR file using WebServicesAssembler and deploy it .and my config.xml:
    <web-service>
    <display-name>Stateful Java Document milkdemo Web Service</display-name>
    <description>Stateful Java Document milkdemo Web Service Example</description>
    <!-- Specifies the resulting web service archive will be stored in ./docws.ear -->
    <destination-path>./milkdemo.ear</destination-path>
    <!-- Specifies the temporary directory that web service assembly tool can create temporary files. -->
    <temporary-directory>./temp</temporary-directory>
    <!-- Specifies the web service will be accessed in the servlet context named "/docws". -->
    <context>/milkdemo</context>
    <!-- Specifies the web service will be stateful -->
    <stateful-java-service>
    <interface-name>com.brightdairy.client.sync.SyncServerDoc</interface-name>
    <class-name>com.brightdairy.client.sync.SyncServerDocImpl</class-name>
    <!-- Specifies the web service will be accessed in the uri named "/docService" within the servlet context. -->
    <uri>/milkdemo</uri>
    <!-- Specifies the location of Java class files ./classes -->
    <java-resource>./classes</java-resource>
    <!-- Specifies that it uses document style SOAP messaging -->
    <message-style>doc</message-style>
    </stateful-java-service>
    <!-- generate the wsdl -->
    <wsdl-gen>
         <wsdl-dir>wsdl</wsdl-dir>
    <!-- over-write a pregenerated wsdl , turn it 'false' to use the pregenerated wsdl-->
         <option name="force">true</option>
         <option name="httpServerURL">http://localhost:8888</option>
    </wsdl-gen>
    <!-- generate the proxy -->
    <proxy-gen>
         <proxy-dir>proxy</proxy-dir>
         <option name="include-source">true</option>
    </proxy-gen>
    </web-service>
    my webservice java file:
    * Title: BrightDairy SOAP demo
    * Description:
    * Copyright: Copyright (c) 2002
    * Company: ufoasia
    * @author
    * @version 1.0
    package com.brightdairy.client.sync;
    import java.sql.*;
    import java.util.Vector;
    import java.util.Iterator;
    import org.w3c.dom.Element;
    import org.w3c.dom.Document;
    import org.w3c.dom.NodeList;
    import oracle.xml.parser.v2.XMLDocument;
    import oracle.xml.parser.v2.XMLElement;
    //import com.brightdairy.client.object.Product;
    import com.brightdairy.client.sync.SyncServerDoc;
    public class SyncServerDocImpl implements SyncServerDoc {
    public SyncServerDocImpl() {
    public Element getProductIDList() {
    Connection connServer = null;
    PreparedStatement stmtServerProduct = null;
    ResultSet rsServerProduct = null;
    Document doc = new XMLDocument();
    Element elProduct = doc.createElement("product");
    doc.appendChild(elProduct);
    long m_msec;
    m_msec = System.currentTimeMillis();
    try {
    connServer = makeConnection();
    System.out.println("1");
    stmtServerProduct = connServer.prepareStatement(
    "SELECT ID FROM " + SERVER_TABLE_PRODUCT );
    System.out.println("");
    rsServerProduct = stmtServerProduct.executeQuery();
    System.out.println("2");
    while(rsServerProduct.next()) {
    Element elID = doc.createElement("id");
    elID.appendChild(doc.createTextNode(rsServerProduct.getString("ID")));
    elProduct.appendChild(elID);
    System.out.println("3");;
    System.out.println("4");
    return doc.getDocumentElement();
    } catch(SQLException e) {
    e.printStackTrace();
    System.out.println("SQL exception has occured");
    System.out.println(e.getMessage());
    return doc.getDocumentElement();
    }finally {
    try {
    rsServerProduct.close();
    stmtServerProduct.close();
    connServer.close();
    m_msec = System.currentTimeMillis() - m_msec;
    System.out.println("6");
    System.out.println("getProductIDList:It take time:" m_msec/1000 "s");
    } catch(Exception e1) {}
    Now my firts question: when i generate the proxy WebServicesAssembler will failure (couldn't import jar.....) and i had imported all jar files,But if i commented proxy-gen , no error.
    and my second question: I commented proxy-gen and deployed ite and success. when i invoked it through web page , then error:
    java.lang.IllegalArgumentException: No Serializer found to serialize a 'org.w3c.
    dom.Element' using encoding style 'http://schemas.xmlsoap.org/soap/encoding/'.
    at org.apache.soap.util.xml.XMLJavaMappingRegistry.querySerializer(XMLJa
    vaMappingRegistry.java:157)
    at org.apache.soap.encoding.soapenc.ParameterSerializer.marshall(Paramet
    erSerializer.java:106)
    at org.apache.soap.rpc.RPCMessage.marshall(RPCMessage.java:265)
    at org.apache.soap.Body.marshall(Body.java:148)
    at org.apache.soap.Envelope.marshall(Envelope.java:203)
    at org.apache.soap.Envelope.marshall(Envelope.java:161)
    at oracle.j2ee.ws.InvocationWrapper.invoke(InvocationWrapper.java:309)
    at oracle.j2ee.ws.RpcWebService.doGetRequest(RpcWebService.java:540)
    at oracle.j2ee.ws.BaseWebService.doGet(BaseWebService.java:1106)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:740)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
    at com.evermind.server.http.ServletRequestDispatcher.invoke(ServletReque
    stDispatcher.java:721)
    at com.evermind.server.http.ServletRequestDispatcher.forwardInternal(Ser
    vletRequestDispatcher.java:306)
    at com.evermind.server.http.HttpRequestHandler.processRequest(HttpReques
    tHandler.java:767)
    at com.evermind.server.http.HttpRequestHandler.run(HttpRequestHandler.ja
    va:259)
    at com.evermind.server.http.HttpRequestHandler.run(HttpRequestHandler.ja
    va:106)
    at EDU.oswego.cs.dl.util.concurrent.PooledExecutor$Worker.run(PooledExec
    utor.java:803)
    at java.lang.Thread.run(Thread.java:484)
    I took much time and couln't get answer ,please help me!!!!!!!!!!!!

    Yeah!
    I have resolved it .
    It take me one day time!
    my error is 1: Element which I used is no namespace.
    2: no import enough jar files
    just so so .
    sorry! I am poor in English

Maybe you are looking for

  • How to Create a Cube Based on other Cubes?

    I want to create a cube that is sourced from other cubes. My situation is I have a number of cubes based on individual products and I want to create a cross-product cube that combines the individual product cubes at a common dimensional grain. e.g :

  • How to handle the errors in BDC Session method

    Hi All, I am uploading Material Master (MM01) records using BDC Session Method.my problem is when i am running the program, all the error records are going to flat file.how can i correcting the error records and after correction how can i re-process

  • Repacking Groupwise using AdminStudio Repackager

    Hi, I wonder if anyone has encounter this before. I'm trying to repacking groupwise client 8.02 into a MSI so i could push via ZCM. Used 2 clean WinXP SP2 and SP3 guest machine to repackaged (AdminStudio Standalone Repackager) the groupwise installer

  • I can't install any application of App Catalog

    These morning I couldn't update my apps. My Pre said me I was disconnected from my Palm Profile and Reset. This erased my data. After that I can't install my apps. I've tried to pass WebOS Doctor and full erase, and the problem still continues. More

  • Reassign text element to a different package?

    Hi All, I want to reassign the program text elements to a different package. Note: I dont want to reassign program, have to reassign text elements only. Kindly help. Thanks, Navneeth K.