Problem displaying Word 2002 RTF files in JEditorPane

Hi all,
I am having a problem displaying RTF files created in Word 2002/Office XP in a JEditorPane.
Our code, which does the usual stuff:
JEditorPane uiViewNarrativeEda = new JEditorPane();
uiViewNarrativeEda.setContentType(new RTFEditorKit().getContentType());
FileInputStream inDocument = new FileInputStream("c:/temp/testing.rtf"); uiViewNarrativeEda.read(inDocument, "");
inDocument.close();
works just FINE with RTF files created in Word 97, WordPad etc, but it seems that Word 2002 adds some tags to the RTF file that the RTFReader cannot handle.
For example, I believe the following exception is due to the new \stylesheet section that Word 2002 adds to the RTF file:
java.lang.NullPointerException:
     at javax.swing.text.rtf.RTFReader$StylesheetDestination$StyleDefiningDestination.close(RTFReader.java:924)
     at javax.swing.text.rtf.RTFReader.setRTFDestination(RTFReader.java:254)
     at javax.swing.text.rtf.RTFReader.handleKeyword(RTFReader.java:484)
     at javax.swing.text.rtf.RTFParser.write(RTFParser.java, Compiled Code)
     at javax.swing.text.rtf.AbstractFilter.readFromReader(AbstractFilter.java:111)
     at javax.swing.text.rtf.RTFEditorKit.read(RTFEditorKit.java:129)
     at javax.swing.text.JTextComponent.read(JTextComponent.java:1326)
     at javax.swing.JEditorPane.read(JEditorPane.java:387)
Does anyone have similar problems or knows how I could get around this?
I thought about writing a parser that replaces the \stylesheet section with one that works but that seems a lot of work and it does not always work (I tried that by copying and pasting...).
Maybe I could replace the RTF converter that Word 2002 is using with another one - but how?

Hello again,
I found out that the 2002 version of MS Word writes a lot more of data into the file than e.g. Wordpad does.
There is one section that causes the problem, its called "\stylesheet".
My workaround (working in my case) is to wrap the input stream of the RTF document and remove this section (only in memory).
See example implementation:
<<<<<<<<<<<<<<<<<<<<<<< SOURCE CODE<<<<<<<<<<<<<
* Copyright 2004 DaimlerChrysler TSS.
* All Rights Reserved.
* Last Change $Author: wiedenmann $
* At $Date: 2004/03/31 11:08:54CEST $.
package com.dcx.tss.swing;
import java.io.*;
* This class provides a workaround for parse errors in the
* {@link javax.swing.text.rtf.RTFEditorKit}. These errors are caused
* by new format specification for RichTextFormat (RTF V1.7).<br>
* <br>
* The workaround is to filter out a section of the RFT document
* which causes an exception during parsing it. This section has no
* impact on the display of the document, it just contains some
* meta information used by MS Word 2002.<br>
* The whole document will be loaded into memory and then the section
* will be deleted in memory, there is no affect to the document
* directly (on file system).<br>
* <br>
* <i>This workaround is provided without any warranty of completely solving
* the problem.</i>
* @version $Revision: 1.1 $
* @author Wiedenmann
public class RtfInputStream extends FilterReader {
/** Search string for start of the section. */
private static final String SEC_START = "{\\stylesheet";
/** Search string for end of the section. */
private static final String SEC_END = "}}";
/** Locale store for the document data. */
private final StringBuffer strBuf = new StringBuffer();
* Wrapper for the input stream used by the RTF parser.<br>
* Here the complete document will be loaded into a string buffer
* and the section causes the problems will be deleted.<br>
* <br>
* @param in Stream reader for the document (e.g. {@link FileReader}).
* @throws IOException in case of I/O errors during document loading.
public RtfInputStream( final Reader in ) throws IOException {
super( in );
int numchars;
final char[] tmpbuf = new char[2048];
// read the whole document into StringBuffer
do {
numchars = in.read( tmpbuf, 0, tmpbuf.length );
if ( numchars != -1 ) {
strBuf.append( tmpbuf, 0, numchars );
} while ( numchars != -1 );
// finally delete the problem making section
deleteStylesheet();
* Deletion of the prblematic section.
private void deleteStylesheet() {
// find start of the section
final int start = strBuf.indexOf( SEC_START );
if ( start == -1 ) {
// section not contained, so just return ...
return;
// find end of section
final int end = strBuf.indexOf( SEC_END, start );
// delete section
strBuf.delete( start, end + 2 );
* Read characters into a portion of an array.<br>
* The data given back will be provided from local StringBuffer
* which contains the whole document.
* @param buf Destination buffer.
* @param off Offset at which to start storing characters -
* <srong>NOT RECOGNIZED HERE.</strong>.
* @param len Maximum number of characters to read.
* @return The number of characters read, or -1 if the end of the
* stream has been reached
* @exception IOException If an I/O error occurs
public int read( final char[] buf, final int off, final int len ) throws IOException {
if ( strBuf.length() == 0 ) {
// if buffer is empty end of document is reached
return -1;
// fill destination array
int byteCount = 0;
for (; byteCount < len; byteCount++) {
if ( byteCount == strBuf.length() ) {
// end reached, stop filling
break;
// copy data to destination array
buf[byteCount] = strBuf.charAt( byteCount );
// delete to copied data from local store
strBuf.delete( 0, byteCount + 1 );
return byteCount;
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
Integration of the warpper looks like:
RtfInputStream inDocument = new RtfInputStream( new FileReader("test.rtf"));
Document doc = rtf.createDefaultDocument();
rtf.read(inDocument, doc, 0 );
Hope this helps - for me it did :-)
Timo Wiedenmann
DaimlerChrysler TSS, Germany

Similar Messages

  • Problem in saving modified rtf file in jsp

    hi,
    I have [b]problem in saving modified rtf file in jsp. My scenario is like this:
    I need to open rtf file in jsp and allow user to modify it, after user modifies rtf file in browser, user will press send button. After user pressing send button rtf has to be saved into destination directory(the directory from which its been fetched. I appreciate if any one could send me relevant code for the same.
    thanks
    ram

    1) RTF is not opened in your browser, but in an application that is set to handle the file type (like Word or Wordpad)
    2) from the web you have no control over what that application does
    3) conclusion: what you want is not possible using the web
    Other than that, asking for code without showing that you put some effort into the problem yourself is a sure way of getting flamed. You should know that by now, since you registered more than 2 years ago...

  • Placing Microsoft Word 7 RTF files in PageMaker 6.0 document

    I am a weekly newspaper editor. For years I have written my articles on a PC at home using Microsoft Word 2000, saved them to disc as RTF files, transferred the RTF files to our Mac (running OS 9.2.2) at work, and placed them into PageMaker 6.0 documents with no problems.
    I now have a new PC at home running Microsoft Office Word 7. When I attempt to place the RTF files produced by Microsoft Word 7 into a PageMaker 6.0 document at work (on the Mac running OS 9.2.2) I get the following error messages: RTF import syntax warning: Unrecognized character set, mac character set used. When I click OK the same message repeats. When I click OK a second time I get a different message:
    RTF import syntax warning, unrecognized token.
    Is there anything I can do to get these Word 7 RTF files to work with our old Macs?
    I forgot to inform you my new PC operating system at home is Windows Vista Home Premium.
    --Roger W. Bonham

    You might be able to save your word file as a Macintosh word 6 file or Word 97/98 file. That should help. You might, like Buko suggests, upgrade to PageMaker 6.5 and then get the free upgrade to 6.5.2.
    It might also work to save your word file as a text only file.
    Upgrading your PageMaker should get rid of your Word woes, but beware of recent Word apps, which have no support from PageMaker.

  • How can display word 2007 document file as a read only on web browser

    hi,
    i want to display word 2007 document file as a read only that means non editable file. At present i am displaying word file by using response object. please help me.
    Thanks,
    Raj

    Hi dear,
    Try with the sample code which has given in below link....
    http://forums.devshed.com/java-help-9/need-help-reading-word-document-with-jsp-20316.html
    ---Vidya
    Message was edited by:
    ragas

  • Unable to combine microcsoft word or rtf files when creating a .pdf

    We cannot add microsoft word or .rtf files when trying to combine them into a single .pdf file..
    When you click on Add files..the word or .rtf files are greyed out and you
    cannot select them..
    We are using Mountain Lion OS (ltatest version) and adobe acrobat version 10.1.5

    Before Acrobat XI, it was only possible in Windows, not on a Macintosh.
    http://indesignsecrets.com/new-acrobat-xi-and-reader-xi-can-change-workflows.php
    "In previous versions of Acrobat, Mac users were stymied when you wanted to open a Microsoft Word, PowerPoint, or Excel file into Acrobat to convert it to PDF, or to include these files when combining documents together. Now, if you have Microsoft Office installed on your Mac, you can include these files. (There are still no PDF Maker plug-ins installed on the Mac, and hyperlink and bookmark export from Word is not yet supported.)"

  • How to display data from *.rtf file with apex in user-frienldy format?

    Hello!
    Well, in my database I have column "Problem" which type is CLOB, and there is text from some *.rtf file, e.g.
    "{\rtf1\ansi\deff0{\fonttbl{\f0\fnil\fcharset238{\*\fname Arial;}Arial CE;}{\f1\fmodern\fcharset238{\*\fname Courier New;}Courier New CE;}{\f2\fnil Arial;}} {\colortbl ;\red0\green0\blue0;\red0\green0\blue68;} \viewkind4\uc1\pard\cf1\lang1045\f0\fs20 Dla podanego poni\'bfej dokumentu XML zdefiniuj schematy XML (pliki XML-Schema), kt\'f3re pozwoli\'b3yby na jego walidacj\'ea. Przy definicji ka\'bfdego ze schemat\'f3w okre\'9cl jego nazw\'ea. \par \par \pard\cf2\b\f1 <?xml version="1.0" encoding="UTF-8"?> \par <s3:A1 xmlns:s1="udasie" xmlns:s2="czy" xmlns:s3="nie" \par xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" \par xsi:schemaLocation="nie schemat3.xsd czy schemat2.xsd" \par C3="u"> \par \lang1033 <C3>d</C3> \par <B2>a</B2> \par <s1:A1 s1:A1="s"> \par \lang1045 <s1:B2>i</s1:B2> \par <s1:C3>e</s1:C3> \par <s2:B2> \par <A1>na pewno</A1> \par </s2:B2> \par </s1:A1> \par </s3:A1>\fs28 \par \pard\cf1\b0\f2\fs20 \par } ?
    And the problem is:
    in my APEX appliactions I only want to display this *.rtf text in user-friendly format (http://cerber.cs.put.poznan.pl/~inf71287/screen.png).
    Is there any simple way to do this?
    This is how it looks now: http://cerber.cs.put.poznan.pl/~inf71287/not_good.png - unreadable ;-)
    Thanks for any suggestions :)
    Buczuss
    Message was edited by:
    Buczuss

    A new preference has been added to customize the import delimiter in main code line. This should be available as part of future release.

  • Problem displaying CLOB in text file

    Hello All,
    I have a problem displaying the content from the database in notepad. When I click on a link on my jsf screen, I retrieve the data and display it in notepad.
    I have my text content stored in the database with CLOB datatype. When I look in the database the data looks in the following format:
    ---------STARTS FROM NEXT LINE-------------
    The firm, known for its keen oversight of products, has been the subject of complaints from firms who have had apps blocked from the store. Some developers have complained that the company's rules seem inconsistent.
    Some have found apps blocked after seemingly minor updates, or for having content deemed inappropriate by them. In light of this, and after careful consideration, I believe it is unnecessary to sign this measure at this time.
    Sincerely,
    ABC
    ----------ENDS IN THE PREVIOUS LINE------------
    Now when I display this content onto the notepad, all the spaces and new line characters are lost, and the entire display looks awkward. This is how it looks:
    The firm, known for its keen oversight of products, has been the subject of complaints from firms who have had apps blocked from the store. Some developers have complained that the company's rules seem inconsistent.[]Some have found apps blocked after seemingly minor updates, or for having content deemed inappropriate by them. In light of this, and after careful consideration, I believe it is unnecessary to sign this measure at this time.[]Sincerely,[]ABC
    All the new line characters are lost and it just puts some junk character in place of a new line.
    When I copy the same text onto textpad, everything is alright and it displays exactly the way it is present in the database. I am also open to display the content in html, but in HTML it doesn't even display me the junk character in place of new line. It is just one single string without any line separators.
    I am using the following code to put the content into the text.
    public String writeMessage(){
       OutputStream outStream = null;
       HttpServletResponse response = getServletResponseFromFacesContext();
       Reader data = null;
       Writer writer = null;
       try{
          response.reset();
          response.setContentType("text/plain; charset=UTF-8");
          response.setHeader("Content-Disposition","attachment; filename="+id+"_Message.txt");
          outStream = response.getOutputStream();
          QueryRemote remote = serviceLocator.getQueriessEJB();
          data = remote.retrieveGovernorsVetoMessage(billId);
          writer = new BufferedWriter(new OutputStreamWriter( outStream, "UTF-8" ) );
          int charsRead;
          char[] cbuf = new char[1024];
          while ((charsRead = data.read(cbuf)) != -1) {
             System.out.println(charsRead);
          writer.write(cbuf, 0, charsRead);
          writer.flush();
       }catch(Exception ex){
          ex.printStackTrace();
       }finally{
          //Close outStream, data, writer
          facesContext.responseComplete();
       return null;
    }Any help or hints on resolving this issue would be highly appreciated.
    Thanks.

    The data is imported from a third party application to my database. It doesn't display any newline characters when I view the data.
    But when I do a regular expression search on text pad, I could see that my clob contains \n as the new line character. Is there a way to replace \n with \n\r while writing the data.
    Thanks.

  • JEditorPane - How to display XML Linked HTML File in JEditorPane ?

    Dear Friends,
    I have a HTML File consisting of stylesheet, xml linked (for data) and with headers, footers...
    When i called a ordinary html file using setpage property of JEditorpane..it's working no problem...but when i call the html file having xml linked or buttons...it's not properly displayed....
    If anybody hits this problem....pls...help me....
    Regards,
    V.Prasanna

    If you only need to display it, consider your HttpServletRequest just as byte stream. :) Just read from ServletInputStream and write it back into ServletOutputStream of HttpServletResponse.
    If you want to process incoming XML, please give some details first, what exactly you want to do. :)

  • Problem displaying characters from pdf file in Preview.app

    Hi,
    I hope someone can help with this problem.
    I have some issues with the display of pdf files on OSX. The problems are with ligatures like 'fl' which Preview.app displays incorrectly as 'oeu'. There are other symbols which Preview also displays incorrectly.
    This problem is not affected by cleaning the font cache and as far as I can tell all the fonts are present and correct. I am guessing the problem has something to do with Preview finding a different version of the Times or TimesRoman font than Adobe Reader uses, and so it gets the wrong symbol, but I'm not sure.
    How can I ensure that Preview uses the same fonts as Adobe Reader? and how can I get Preview to render my pdf's correctly?
    Here is a sample of the problem with Preview.app (4.1):
    !http://farm4.static.flickr.com/3456/33599073294296beb1a8m.jpg!
    and with Adobe Reader (9.0.0)- correctly rendered:
    !http://farm4.static.flickr.com/3448/335990717548aa12e576m.jpg!

    My computer automatically open PDF inside the Safari
    window, but I wish it would go back to opening it
    externally via Adobe. (maybe we should trade
    computers:-)
    Anyway, we have the same question.
    How do we control whether PDF launches internal to
    Safari, or external in Adobe?
    This is what I would like to as well. I often have a lot of pdf files I need to open and then save to my hard drive. When I click on a pdf file on a website Safari opens it and then I need to right click in the document to open it with Adobe. How can I get it to open in Adobe the first time without having to right click after it opens in Safari?
    Thanks!

  • How can I get an RTF file to open properly in MS Word?

    I'm using Coldfusion 8 and trying get it to export to Microsoft Word an RTF file  that was also created in Word, and is stored on the server. The problem is that when Word opens from the browser, it displays the RTF code for the document as if I'd opened the file in a text editor. The extension is ".rtf", and I've tried using ".doc" and ".docx" but nothing works. And even though Word opens it with an rtf extension, if I do a "Save As", it wants to save the file as an .htm file. I've also tried changing the content-type to "application/msword" but this didn't work. Also if I use OpenOffice instead of MS Word it still doesn't work. My code is below, if anyone could tell me what I'm doing wrong it would be very appreciated.
    <cfset formFile = "test.rtf">
    <cfset pathToRTF =  GetDirectoryFromPath(GetCurrentTemplatePath()) & formFile />
        <!---<cfset rtfForm = FileRead(pathToRTF) />--->
        <cffile
                action="read"
                file="#pathToRTF#"
                variable="rtfForm"
                >
    <cfcontent type="application/rtf">
    <cfheader name="Content-Type" value="application/rtf">
    <CFHEADER NAME="Content-Disposition" VALUE="filename=test.rtf">
    <cfoutput>
        #rtfForm#
    </cfoutput>

    What kind of local files are you trying to open and what kind of content is on the pages?
    Are that files that you've saved from the internet?

  • Displaying Word document in JEditorPane

    Hi,
    I (urgently) need to display a .doc file in a JEditorPane component..
    Can anyone sent here some simply piece of code??
    Thanx in advance!!
    Dewsqa

    Hey
    did you manage to find that out! Im trying to do the same, only have hours left to do so!
    If anyone knows how, please let me know.
    I have it all set up to display the file, just it will only read .txt files. How do you get it to display word docs?
    pane = new JEditorPane();
            try {
                pane.getEditorKit().read(new java.io.FileReader("file.doc"), pane.getDocument(), 0);
                pane.setEditable(false);
            catch (Exception e) {
                e.printStackTrace();
            Thanks Much appreciated

  • Not able to upload RTF files

    There are 2 database instances: Development and Production. Last month, there was a database refresh in development(cloned with the production), after which we are not able to upload the files in dev instance, but the prod instance is working fine as usual.
    There is a problem while uploading any RTF file using XML Publisher. An error message is displayed: "You have encountered an unexpected error. Please contact the System Administrator for assistance." Request you to please guide me. I am ready for any assistance required.
    Please find the exception details as seen in the diagnostics for the above page where the error message was displayed.
    oracle.apps.fnd.framework.OAException: java.sql.SQLException: No corresponding row found in XDO_LOBS
         at oracle.apps.fnd.framework.OAException.wrapperException(OAException.java:888)
         at oracle.apps.fnd.framework.OAException.wrapperException(OAException.java:862)
         at oracle.apps.fnd.framework.OAException.wrapperInvocationTargetException(OAException.java:985)
         at oracle.apps.fnd.framework.server.OAUtility.invokeMethod(OAUtility.java:210)
         at oracle.apps.fnd.framework.server.OAApplicationModuleImpl.invokeMethod(OAApplicationModuleImpl.java:679)
         at oracle.apps.xdo.oa.template.webui.TemplateFileAddCO.processFormRequest(TemplateFileAddCO.java:362)
         at oracle.apps.fnd.framework.webui.OAWebBeanHelper.processFormRequest(OAWebBeanHelper.java:799)
         at oracle.apps.fnd.framework.webui.OAWebBeanContainerHelper.processFormRequest(OAWebBeanContainerHelper.java:363)
         at oracle.apps.fnd.framework.webui.OAPageLayoutHelper.processFormRequest(OAPageLayoutHelper.java:1118)
         at oracle.apps.fnd.framework.webui.beans.layout.OAPageLayoutBean.processFormRequest(OAPageLayoutBean.java:1579)
         at oracle.apps.fnd.framework.webui.OAWebBeanHelper.processFormRequestChildren(OAWebBeanHelper.java:995)
         at oracle.apps.fnd.framework.webui.OAWebBeanHelper.processFormRequestChildren(OAWebBeanHelper.java:961)
         at oracle.apps.fnd.framework.webui.OAWebBeanHelper.processFormRequest(OAWebBeanHelper.java:816)
         at oracle.apps.fnd.framework.webui.OAWebBeanContainerHelper.processFormRequest(OAWebBeanContainerHelper.java:363)
         at oracle.apps.fnd.framework.webui.beans.form.OAFormBean.processFormRequest(OAFormBean.java:395)
         at oracle.apps.fnd.framework.webui.OAWebBeanHelper.processFormRequestChildren(OAWebBeanHelper.java:995)
         at oracle.apps.fnd.framework.webui.OAWebBeanHelper.processFormRequestChildren(OAWebBeanHelper.java:961)
         at oracle.apps.fnd.framework.webui.OAWebBeanHelper.processFormRequest(OAWebBeanHelper.java:816)
         at oracle.apps.fnd.framework.webui.OAWebBeanContainerHelper.processFormRequest(OAWebBeanContainerHelper.java:363)
         at oracle.apps.fnd.framework.webui.beans.OABodyBean.processFormRequest(OABodyBean.java:363)
         at oracle.apps.fnd.framework.webui.OAPageBean.processFormRequest(OAPageBean.java:2633)
         at oracle.apps.fnd.framework.webui.OAPageBean.preparePage(OAPageBean.java:1659)
         at oracle.apps.fnd.framework.webui.OAPageBean.preparePage(OAPageBean.java:497)
         at oracle.apps.fnd.framework.webui.OAPageBean.preparePage(OAPageBean.java:418)
         at oa_html._OA._jspService(_OA.java:88)
         at oracle.jsp.runtime.HttpJsp.service(HttpJsp.java:119)
         at oracle.jsp.app.JspApplication.dispatchRequest(JspApplication.java:417)
         at oracle.jsp.JspServlet.doDispatch(JspServlet.java:267)
         at oracle.jsp.JspServlet.internalService(JspServlet.java:186)
         at oracle.jsp.JspServlet.service(JspServlet.java:156)
         at javax.servlet.http.HttpServlet.service(HttpServlet.java:588)
         at org.apache.jserv.JServConnection.processRequest(JServConnection.java:456)
         at org.apache.jserv.JServConnection.run(JServConnection.java:294)
         at java.lang.Thread.run(Thread.java:595)
    ## Detail 0 ##
    java.sql.SQLException: No corresponding row found in XDO_LOBS
         at oracle.apps.xdo.oa.schema.server.LobHelper.updateLob(LobHelper.java:116)
         at oracle.apps.xdo.oa.schema.server.LobHelper.updateLob(LobHelper.java:286)
         at oracle.apps.xdo.oa.schema.server.LobHelper.updateLob(LobHelper.java:205)
         at oracle.apps.xdo.oa.schema.server.TemplateHelper.updateTemplateFile(TemplateHelper.java:3900)
         at oracle.apps.xdo.oa.template.server.TemplatesAMImpl.addTemplateFile(TemplatesAMImpl.java:611)
         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 oracle.apps.fnd.framework.server.OAUtility.invokeMethod(OAUtility.java:189)
         at oracle.apps.fnd.framework.server.OAApplicationModuleImpl.invokeMethod(OAApplicationModuleImpl.java:679)
         at oracle.apps.xdo.oa.template.webui.TemplateFileAddCO.processFormRequest(TemplateFileAddCO.java:362)
         at oracle.apps.fnd.framework.webui.OAWebBeanHelper.processFormRequest(OAWebBeanHelper.java:799)
         at oracle.apps.fnd.framework.webui.OAWebBeanContainerHelper.processFormRequest(OAWebBeanContainerHelper.java:363)
         at oracle.apps.fnd.framework.webui.OAPageLayoutHelper.processFormRequest(OAPageLayoutHelper.java:1118)
         at oracle.apps.fnd.framework.webui.beans.layout.OAPageLayoutBean.processFormRequest(OAPageLayoutBean.java:1579)
         at oracle.apps.fnd.framework.webui.OAWebBeanHelper.processFormRequestChildren(OAWebBeanHelper.java:995)
         at oracle.apps.fnd.framework.webui.OAWebBeanHelper.processFormRequestChildren(OAWebBeanHelper.java:961)
         at oracle.apps.fnd.framework.webui.OAWebBeanHelper.processFormRequest(OAWebBeanHelper.java:816)
         at oracle.apps.fnd.framework.webui.OAWebBeanContainerHelper.processFormRequest(OAWebBeanContainerHelper.java:363)
         at oracle.apps.fnd.framework.webui.beans.form.OAFormBean.processFormRequest(OAFormBean.java:395)
         at oracle.apps.fnd.framework.webui.OAWebBeanHelper.processFormRequestChildren(OAWebBeanHelper.java:995)
         at oracle.apps.fnd.framework.webui.OAWebBeanHelper.processFormRequestChildren(OAWebBeanHelper.java:961)
         at oracle.apps.fnd.framework.webui.OAWebBeanHelper.processFormRequest(OAWebBeanHelper.java:816)
         at oracle.apps.fnd.framework.webui.OAWebBeanContainerHelper.processFormRequest(OAWebBeanContainerHelper.java:363)
         at oracle.apps.fnd.framework.webui.beans.OABodyBean.processFormRequest(OABodyBean.java:363)
         at oracle.apps.fnd.framework.webui.OAPageBean.processFormRequest(OAPageBean.java:2633)
         at oracle.apps.fnd.framework.webui.OAPageBean.preparePage(OAPageBean.java:1659)
         at oracle.apps.fnd.framework.webui.OAPageBean.preparePage(OAPageBean.java:497)
         at oracle.apps.fnd.framework.webui.OAPageBean.preparePage(OAPageBean.java:418)
         at oa_html._OA._jspService(_OA.java:88)
         at oracle.jsp.runtime.HttpJsp.service(HttpJsp.java:119)
         at oracle.jsp.app.JspApplication.dispatchRequest(JspApplication.java:417)
         at oracle.jsp.JspServlet.doDispatch(JspServlet.java:267)
         at oracle.jsp.JspServlet.internalService(JspServlet.java:186)
         at oracle.jsp.JspServlet.service(JspServlet.java:156)
         at javax.servlet.http.HttpServlet.service(HttpServlet.java:588)
         at org.apache.jserv.JServConnection.processRequest(JServConnection.java:456)
         at org.apache.jserv.JServConnection.run(JServConnection.java:294)
         at java.lang.Thread.run(Thread.java:595)
    java.sql.SQLException: No corresponding row found in XDO_LOBS
         at oracle.apps.xdo.oa.schema.server.LobHelper.updateLob(LobHelper.java:116)
         at oracle.apps.xdo.oa.schema.server.LobHelper.updateLob(LobHelper.java:286)
         at oracle.apps.xdo.oa.schema.server.LobHelper.updateLob(LobHelper.java:205)
         at oracle.apps.xdo.oa.schema.server.TemplateHelper.updateTemplateFile(TemplateHelper.java:3900)
         at oracle.apps.xdo.oa.template.server.TemplatesAMImpl.addTemplateFile(TemplatesAMImpl.java:611)
         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 oracle.apps.fnd.framework.server.OAUtility.invokeMethod(OAUtility.java:189)
         at oracle.apps.fnd.framework.server.OAApplicationModuleImpl.invokeMethod(OAApplicationModuleImpl.java:679)
         at oracle.apps.xdo.oa.template.webui.TemplateFileAddCO.processFormRequest(TemplateFileAddCO.java:362)
         at oracle.apps.fnd.framework.webui.OAWebBeanHelper.processFormRequest(OAWebBeanHelper.java:799)
         at oracle.apps.fnd.framework.webui.OAWebBeanContainerHelper.processFormRequest(OAWebBeanContainerHelper.java:363)
         at oracle.apps.fnd.framework.webui.OAPageLayoutHelper.processFormRequest(OAPageLayoutHelper.java:1118)
         at oracle.apps.fnd.framework.webui.beans.layout.OAPageLayoutBean.processFormRequest(OAPageLayoutBean.java:1579)
         at oracle.apps.fnd.framework.webui.OAWebBeanHelper.processFormRequestChildren(OAWebBeanHelper.java:995)
         at oracle.apps.fnd.framework.webui.OAWebBeanHelper.processFormRequestChildren(OAWebBeanHelper.java:961)
         at oracle.apps.fnd.framework.webui.OAWebBeanHelper.processFormRequest(OAWebBeanHelper.java:816)
         at oracle.apps.fnd.framework.webui.OAWebBeanContainerHelper.processFormRequest(OAWebBeanContainerHelper.java:363)
         at oracle.apps.fnd.framework.webui.beans.form.OAFormBean.processFormRequest(OAFormBean.java:395)
         at oracle.apps.fnd.framework.webui.OAWebBeanHelper.processFormRequestChildren(OAWebBeanHelper.java:995)
         at oracle.apps.fnd.framework.webui.OAWebBeanHelper.processFormRequestChildren(OAWebBeanHelper.java:961)
         at oracle.apps.fnd.framework.webui.OAWebBeanHelper.processFormRequest(OAWebBeanHelper.java:816)
         at oracle.apps.fnd.framework.webui.OAWebBeanContainerHelper.processFormRequest(OAWebBeanContainerHelper.java:363)
         at oracle.apps.fnd.framework.webui.beans.OABodyBean.processFormRequest(OABodyBean.java:363)
         at oracle.apps.fnd.framework.webui.OAPageBean.processFormRequest(OAPageBean.java:2633)
         at oracle.apps.fnd.framework.webui.OAPageBean.preparePage(OAPageBean.java:1659)
         at oracle.apps.fnd.framework.webui.OAPageBean.preparePage(OAPageBean.java:497)
         at oracle.apps.fnd.framework.webui.OAPageBean.preparePage(OAPageBean.java:418)
         at oa_html._OA._jspService(_OA.java:88)
         at oracle.jsp.runtime.HttpJsp.service(HttpJsp.java:119)
         at oracle.jsp.app.JspApplication.dispatchRequest(JspApplication.java:417)
         at oracle.jsp.JspServlet.doDispatch(JspServlet.java:267)
         at oracle.jsp.JspServlet.internalService(JspServlet.java:186)
         at oracle.jsp.JspServlet.service(JspServlet.java:156)
         at javax.servlet.http.HttpServlet.service(HttpServlet.java:588)
         at org.apache.jserv.JServConnection.processRequest(JServConnection.java:456)
         at org.apache.jserv.JServConnection.run(JServConnection.java:294)
         at java.lang.Thread.run(Thread.java:595)

    I had raised one SRS request, and did get the solution. This is what was the reply:
    You are using an old version of XML Publisher
    Please apply the Patch 5472959 to solve the issue.
    For more details about the last version XML Publisher 5.6.3"
    About Oracle XML Publisher Release 5.6.3 (Doc ID 422508.1)
    My question is when both the prod and test instance are same, then why there is a need to apply patch in test instance when the prod is working fine?

  • Images in RTF file do not display in WordPad

    I inserted some images into a flowdocument, then save it as a rtf file.
                Image photo = new Image();
                BitmapImage photoFile = new BitmapImage();
                photoFile.BeginInit();
                photoFile.UriSource = new Uri("image.bmp", UriKind.Relative);
                photoFile.EndInit();
                photo.Source =photoFile;      
                Paragraph pPhoto = new Paragraph();
                pPhoto.Inlines.Add(photo);
                flowdoc.Blocks.Add(pPhoto);
    When I open the rtf file with wordpad, all the images are lost. But they can be displayed in Word.
    Why does that happen?
    Thx.

    WordPad (at least version 6.1 on W7) cannot display linked images, MSWord can. WordPad
    can display embedded images. But the format seems to be some uncompressed WindowsMetaFile8 format, which may increase the storage footprint, compared to eg. PNG graphics, drastically. (Open a Wordpad RTF in Notepad, you'll see...)
    A cross-check against the DotNET 1.1 RTF control shows the same as in Wordpad, linked images do not show up. That leads to the assumption that Windows Forms as well as Wordpad are based on the Windows Common RTF Control, and that control seems
    not to support linked images.
    I'm not quite sure yet, but WPF converts RTF content to XAML (which is very similar to HTML), so it does not rely on the Windows RTF common control, thus linked images in RTF are not a problem there.
    HTH
    Ulrich

  • View the .rtf file not display the data in BI Publisher Enterprise.

    Hi,
    Platform: OBIEE 10g in NT XPsp2
    View the .rtf file not display the data in BI Publisher Enterprise.
    Step 1, I created Answer-request, create .rtf file with Word and add the request name, Add bar chart and table, preview PDF is working fine with data, Upload this template to Answers, View Template from Answer is working fine with data.
    Step 2, Answers – More Products > BI Publisher > My Folders > Create a new report > Edit > Data Model > New > Type: SQL Query > Data Source: Oracle BI EE > Query Builder > from SupplierSales assign Customer, Periods, Sales Facts (select Region, state, Year, Units Shipped) > Results > Save > Save
    Click Layouts > New > enter Name ….. > Click Layouts > borrows .rtf file in Manage T file > Upload > Save > Click View
    It is showing only the .rtf file without data. Why there is no data?
    Please guide me to solve this issue.
    Thanks,
    Jo

    Thanks for you reply,
    Our scenario is this report is basically a dissconnected mode report... we are developing these reports for mobile clients.
    We dint face this kind of issue while developing other reports.
    So please let us know if you have any idea on why we are facing this issue.
    Regards,
    Maneesh

  • Problem to display Animated Gif from HTML into JEditorPane

    I have a problem displaying animated gif that comes from URL (HTML) into JEditorPane.
    Let me show you the source I have:
    * @author Dobromir Gospodinov
    * @version 1.0
    * Date: Dec 6, 2002
    * Time: 6:47:53 PM
    package test.advertserver;
    import javax.swing.*;
    import java.awt.*;
    import java.io.IOException;
    public class Test {
         public static void main(String[] args) {
              JFrame frame = new JFrame();
              JEditorPane ed = new JEditorPane();
              try {
                   ed.setPage("http://localhost:8200/servlet?key=value");
              } catch (IOException e) {
                   e.printStackTrace();
              JPanel panel = new JPanel();
              panel.setPreferredSize(new Dimension(500, 500));
              panel.add(ed);
              frame.getContentPane().add(panel);
              frame.pack();
              frame.setVisible(true);
    }Part of the returned from servlet HTML includes an img tag:
    <img src="/images/MyAnimatedGif.gif" alt="animated gif comment" width="480" height="50"  border="0">Let us assume that MyAnimatedGif.gif has 10 frames and gif is looped - when the 10th is dipslayed it has to display the 1st and so on.
    JEditorPane displays frames from 1 to 10 correctly but does not start from the first again. Instead JEditorPane displays a broken image.
    I locate where the problem arise:
    JEditorPane has an HTMLEditorKit that creates javax.swing.text.html.ImageView instance for every IMG tag.
    And here is the problem:
    ImageView has an ImageObserver necessary for the asynchronous image download. ImageObserver has the imageUpdate method. But this imageUpdate method is never called with ALLBITS flag raised up. Instead, after the last frame of MyAnimatedGif.gif is downloaded the imageUpdate method is called with flag ERROR raised up. Obviously this is a bug of Sun's implementation. Finaly the flag ALLBITS has to be received for normal end of image observing. But ALLBITS flag does not come.
    So, can anybody help me how to load an animated gif within JEditorPane completely.
    Thank You in advance,
    Dobromir Gospodinov
    P.S. If somebody of you wants to debbug what happens within ImageView will have to implement it (and related classes too, because of the limited package visability) borrowing the source from Sun's ImageView.

    I'm also having this problem with java 1.4.1 I discovered that some animated gifs work fine, while others stop animating. Running with java 1.3.1 fixed the problem. I'm going to report this as a bug
    Here's my code:
    import java.awt.*;
    import java.io.*;
    import javax.swing.*;
    public class AnimatedGifTester
    extends JFrame
    public static void main(String argv[])
    throws Exception
    new AnimatedGifTester();
    public AnimatedGifTester()
    throws Exception
    String[] images = new String[] {
    "http://www.gif.com/ImageGallery/Animated/Animals/Photographic/dog_running.gif",
    "http://www.gif.com/ImageGallery/Animated/Characters/Cartoon/java.gif",
    "http://www.webdeveloper.com/animations/bnifiles/anielg.gif",
    "http://www.webdeveloper.com/animations/bnifiles/cat2.gif",
    "http://images.animfactory.com/animations/animals/fish/big_fish_swimming_md_wht.gif",
    "http://www.webgenies.co.uk/images/martian.gif",
    "http://www.webdeveloper.com/animations/bnifiles/at_sign_rotating.gif",
    "http://www.webdeveloper.com/animations/bnifiles/arrow_1.gif",
    "http://www.gif.com/ImageGallery/Animated/Characters/Cartoon/javaacro.gif",
    "http://java.sun.com/products/java-media/2D/samples/suite/Image/duke.running.gif",
    "http://www.gif.com/ImageGallery/Animated/SouthPark/Cartoon/stan.gif"
    StringBuffer buffer = new StringBuffer("<html><body>");
    for (int idx = 0; idx < images.length; idx++)
    buffer.append("<img src='" + images[idx] + "'>");
    buffer.append("</body></html>");
    String html = buffer.toString();
    // save a copy of the html to open in a browser so we can see what it's
    // supposed to look like
    BufferedWriter writer = new BufferedWriter(new FileWriter("animatedGifTest.html"));
    writer.write(html);
    writer.close();
    JEditorPane editorPane = new JEditorPane("text/html", html);
    editorPane.setEditable(false);
    getContentPane().add(editorPane);
    setDefaultCloseOperation(EXIT_ON_CLOSE);
    setSize(new Dimension(400, 600));
    show();

Maybe you are looking for

  • Relationship between SAP R/3 and XI

    Hi I have a question. What kindoff relationship exists between an R/3 system and XI system. Is it 1:1 or 1:many. Lets say i have a requirement where i have one r/3 system and 3 EAI system. I want to generate an idoc or rfc from a single r/3 which has

  • Multiple problems w/ iMac

    Hi, Today I had a big problem with my iMac. I already had Bootcamp installed, with XP SP2, and I wanted to install a new expansion of a game, The Sims 2. I did it, and started playing. 10 minutes later, the screen went black and all peripherals went

  • FaceTime v1.0.2 fixed my problems!

    Before 10.6.7 and the FaceTime 1.0.2 update that came with it I couldn't use the app. I could load it, and even connect to calls but no one could hear me with my mic through the facetime cam. After this update I completed my first successful FaceTime

  • Chrome crashing MacBook Pro since updating to 10.7.5

    Updated my mid-2009 Macbook Pro OS to 10.7.5. Since then, any time I try to use Chrome, it crashes the laptop - the only way to restore is to power off and power back on. How do I fix this? Thanks!

  • How do you accept terms for adobe reader on macbook

    how do you accept terms for adobe reader on macbook