Pages to Epub - adding space/carriage returns

I'm building an epub file in Pages, and can't do the simplest thing: Make a couple of blank lines appear before and after section dividers.
If I insert a return character, it disappears in the epub file. If I adjust paragraph settings to provide additional space above and below the section dividers, I get a mysterious question mark that won't go away.
Help!
Thanks.
-- Jon

Never mind. This seems to be a problem only if I set the spacing using a style.
Weird, though...

Similar Messages

  • Adding a carriage return in an alert box

    Hello
    I have a user request to display this alert box in the format below:
    Attention: The owner name has changed on this vessel.
    Current Name: xxxxxxx:
    New Name : yyyyyyy
    Please confirm or deny that this is an owner change.
    Confirm and Deny are the two buttons.
    How can I insert a c arriage return at the end of each text line so the text looks this way in the alert box? I can get it to wrap but it doesn't look right
    can the 'Confirm' and 'Deny' buttons be set to different colors?
    Thanks!

    Use chr(10).
    For example:
    v_alert := 'Attention: The owner name has changed on this vessel.' || chr(10) || 'Current Name: ' || etc....

  • Carriage return in a WD table cell

    Hi,
    I have data in a table cell which I would like to present better by adding a carriage returns so that it appears on more than one line for example as bullet points.
    I can format it using HTML but can’t seem to be able to find out how to set encode to true for that cell.
    Has anyone come across this problem before, or even have a simpler solution.
    Cheers
    Phil

    Hi Phil,
    Check this Multiple Text lines in ONE row of a Table . On what SP level are you?
    Best regards, Maksim Rashchynski.

  • Serious Bug - Carriage Returns in Caption field

    LR for Windows does not handle Carriage Returns/Line Feeds correctly in the metadata Caption field.
    Windows Vista SP1, 32-bit
    Adobe Lightroom 2.4
    Library Module, Grid View
    Initial settings:
    LR Menu bar > Edit > Catalog Settings... > Metadata tab > Editing
    uncheck Offer suggestions from recently entered values
    uncheck Automatically write changes into XMP
    LR Menu bar > View > View options... > Grid View tab > Cell Icons
    check Unsaved Metadata
    Metadata panel: choose the Default Metadata Set.
    Import a JPG file into LR which contains no IPTC metadata.
    LR Menu bar > File > Import Photos from disk... > Choose the JPG file
    In the Import Photos dialog box, Information to Apply:
    Develop Settings: None
    Metadata: None
    Keywords: None
    Click Import.
    Click thumbnail of the JPG file which was Imported.
    In the Metadata panel click Caption field.
    Type "Word1" in the Caption field and press Return/Enter key.
    The Caption field loses focus.
    The Caption field should not lose focus when the Return/Enter key is pressed.
    Click the Caption field and press the Delete key to remove "Word1" from the field.
    In the Caption field type "Word1" and press Ctrl+Return/Enter key.
    As expected, the cursor moves to the line below "Word1" and the Caption field remains in focus.
    Type "Word2" and press Ctrl+Return/Enter key.
    As expected, the cursor moves to the line below "Word2" and the Caption field remains in focus.
    Click the JPG thumbnail and notice a down-arrow icon appears on the thumbnail indicating that the metadata for this JPG has been changed in the LR catalog and that it does not match the IPTC metadata that is embedded in the JPG file on the hard disk. Also notice in the Metadata panel, Metadata Status is "Has been changed".
    Click the down-arrow on the JPG thumbnail.
    See the dialog box that pops up saying "The metadata for this photo has been changed in Lightroom. Save the changes to disk?"
    Click Save.
    Notice on the JPG thumbnail, the down-arrow icon remains visible and does not disappear as it should if the JPG's metadata in the LR catalog and the metadata embedded in the JPG file on the hard disk were the same.
    Also notice in the Metadata panel, Metadata Status is "Has been changed".
    Click LR Menu bar > Edit > Catalog Settings... > Metadata tab > Editing
    check Automatically write changes into XMP
    Click OK.
    Notice on the JPG thumbnail, the down-arrow icon blinks rapidly. Also notice in the Metadata panel that "Metadata Status: Has been changed" blinks rapidly.
    Click LR Menu bar > Edit > Catalog Settings... > Metadata tab > Editing
    uncheck Automatically write changes into XMP
    Notice the blinking stops.
    Using a program that properly handles Carriage Returns/Line Feeds in IPTC metadata, such as Photo Mechanic 4.5, edit the metadata of another JPG file by typing "Word1", pressing the Return/Enter key, and typing "Word2" in the Caption field.
    Import that JPG into LR.
    LR Menu bar > File > Import Photos from disk... > Choose the JPG file
    In the Import Photos dialog box, Information to Apply:
    Develop Settings: None
    Metadata: None
    Keywords: None
    Click Import.
    Click the JPG thumbnail in LR Library Module.
    Notice in the Metadata panel, "Word1Word2" appears in the Caption field, in both the Default Metadata Set and the Large Caption Metadata Set. The CR/LF has been stripped away.
    CR/LFs typed into or pasted into the Large Caption set, also result in the persistence of the down-arrow icon even after metadata is saved to disk. And, if the Automatically write changes into XMP option is checked, the down-arrow icon blinks rapidly. And, if you view the Default set, notice Metadata Status: "Has been changed" blinks rapidly.
    When metadata is saved to disk, the down-arrow icon should disappear from the thumbnail, and in the Metadata panel, Metadata Status should read "Up to date". I would guess the blinking behavior indicates LR is stuck in some kind of loop - it is trying to save the metadata to disk and verify that it has been saved, but it keeps going round in a vicious circle. I also notice there is increased hard drive activity during the blinking behavior.

    Here is a related problem (using Lightroom 3.3, Windows).  When I import photos that have the IPTC caption field created in another program (ThumbsPlus, or IrfanView), carriage returns in the original do not show up in Lightroom.  Does anyone know why, or what to do about it?  I'd like to import lots of photos with existing captions, and some have carriage returns I would like to retain.
    For me, adding a carriage return to the Caption metadata within Lightroom works fine.  In the Library view, using the right panel, I can enter a carriage return using Ctrl+Enter in the Metadata > Default view or in the Metadata > IPTC view.  I can enter a carriage return directly with the Enter key (no Ctrl required) in the Metadata > Large Caption view.  After these entries are saved to the file, they show up correctly in other programs (IrfanView > Image > Properties > IPTC Info)

  • Write to spreadsheet adds carriage return

    I am using build array function to put together a number of strings and build an array of strings.  The build array is in a while loop.  A new line is added to the array every loop.  I am using write to spread sheet function to save the spreadsheet to a file with xls extension.  For some reason, a carriage return is inserted within the array.  The array has 9 columns and a carriage return is put after the fourth column.  I have not added this carriage return.  Does anyone know why write to spreadsheet might automatically add a carriage return and how to remove it?  
    Thank you!
    Solved!
    Go to Solution.

    Hi,
    I took your posted VI and compiled it to an exe.  I do not see the carriage return problem you are describing?
    If you compile the VI you attached, do you see the problem or is it only in the original main application (that you cannot share)?
    If the compiled exe works on your PC, does it also work on the 'different' computer where you see the issue with your original code?  
    -If it does work, then the issue must be in the source code for your original code.  Sometimes, if you re-size string constants, for example, it can be hard to see carriage return's.
    Another thing it could be perhaps, is if you are calling the "write spreadsheet" in two different places in your main code, then the way it works is it will write your two (different) input arrays to separate lines.  If it is as in your example VI though, there should be no carriage return in the "middle" of the array.
    For debug purposes, you could consider making a VI that takes a 1D string array input, iterates over each element in the array and searches for the carriage return character and gives an error/message on what iteration it found it, then you can back-track from there to see in the code responsible for making the string that went into that index.
    QFang
    CLD LabVIEW 7.1 to 2013

  • TEXT datatype in Stored Procedure and concat Carriage returns

    Anyone,
    I am trying to create a stored procedure that will allow me to grab a bunch of 255 Char records in a cursor and concatenate them together adding a carriage return after each row.
    Here is pseudo code would look like:
    CREATE OR REPLACE PROCEDURE myproc IS
       CURSOR c1 IS
          SELECT myVARCHAR_255_col
          From mytable
          where criteria = something
          rec c1%ROWTYPE;
          var_my_new_TEXT TEXT;
    BEGIN
       OPEN c1;
       LOOP
          FETCH c1 INTO rec;
          EXIT WHEN c1%NOTFOUND;
            IF rec.myVARCHAR_255_col IS NOT NULL THEN
                var_my_new_TEXT := CONCAT(rec.myVARCHAR255_col, '%char(13)+char(10)%')
            END IF
       END LOOP;
       CLOSE c1;
    END;There is a bit more to code then this but most important issue is how to deal with TEXT datatype? Should/can it be RAW instead. And also how do I get a CARRIAGE RETURN into the body of the column of type TEXT.
    Thanks in advance,
    Miller

    Is there a specific reason for concatenating 255 characters at a time and returning it? This example may be of help.
    SQL> set long 500
    SQL> DESC MYTABLE
    Name                                      Null?    Type
    COL1                                               NUMBER(2)
    COL2                                               LONG
    SQL> select * from mytable;
          COL1
    COL2
             1
    This text is very long This text is very long This text is very long This text i
    s very long This text is very long This text is very long This text is very long
    This text is very long This text is very long This text is very long This text
    is very long This text is very long This text is very long This text is very lon
    g This text is very long This text is very long This text is very long
    SQL> select length(col2) from mytable;
    select length(col2) from mytable
    ERROR at line 1:
    ORA-00932: inconsistent datatypes: expected NUMBER got LONG
    SQL> select length('This text is very long This text is very long This text is very long This text i
      2  s very long This text is very long This text is very long This text is very long
      3   This text is very long This text is very long This text is very long This text
      4  is very long This text is very long This text is very long This text is very lon
      5  g This text is very long This text is very long This text is very long') from dual;
    LENGTH('THISTEXTISVERYLONGTHISTEXTISVERYLONGTHISTEXTISVERYLONGTHISTEXTISVERYLONG
                                                                                 393
    SQL> R
      1  DECLARE
      2  V_VARIABLE VARCHAR2(4000);
      3  BEGIN
      4  SELECT COL2 INTO V_VARIABLE FROM MYTABLE;
      5  DBMS_OUTPUT.PUT_LINE(SUBSTR(V_VARIABLE,1,255));
      6  DBMS_OUTPUT.PUT_LINE(SUBSTR(V_VARIABLE,256,138));
      7* END;
    This text is very long This text is very long This text is very long This text
    is very long This text is very long This text is very long This text is very
    long This text is very long This text is very long This text is very long This
    text is very long Th
    is text is very long This text is very long This text is very long This text is
    very long This text is very long This text is very long
    PL/SQL procedure successfully completed.
    SQL> SELECT SUBSTR(COL2,1,255) FROM MYTABLE;
    SELECT SUBSTR(COL2,1,255) FROM MYTABLE
    ERROR at line 1:
    ORA-00932: inconsistent datatypes: expected NUMBER got LONG

  • Embedded carriage return

    We have  an application with a textarea that is used for comments, free form text. It seems that if the user enters a line of text, then uses the enter key to go to the next line, it captures the carriage return. When the form is brought up for review, it is completely empty, yet all the data that was entered is in the table.
    If the textarea is entered without using the enter key, the data displays when the form is reviewed.
    I have never encountered this problem before and tried it and it does indeed do what is described above. I entered the textarea without using the enter key and the data displays. I went back to edit and added the enter key to the textarea and the form is completely blank.
    What is going on and how can I prevent this from happening ?

    The data is not missing. It is in table after submit. It is just not showing up when using html/form to review. Using <cfinput type="text" name="field" value="qryField">, etc..., when there is a carriage return used in the textarea.
    We took the textarea data, scrubbed out the carrirage return characters, and reinserted in the table, and then entire form displayed. When I went back to edit the form and added the carriage returns, nothing displayed.
    We have isolated the problem to the carriage return in the text area becuause that is the only thing we have touched so far.

  • XSL mapping of ARTMAS IDoc - carriage returns and white space

    Hi all. I have tried all sorts here and am completely stuck. I am mapping an article master ARTMAS IDoc using XSL mapping and an extra carriage return and white space characters are being added to the FIELD1 and FIELD2 fields of the E1BPE1MARAEXTRT segment and I don't know why! These fields contain all our bespoke field values joined together so they are 229 and 250 characters long respectively, which I think is related to the problem. The mapping program looks like this:
    <xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0">
    <xsl:output method="xml" encoding="UTF-8" omit-xml-declaration="no" indent="yes"/>
    <xsl:template match="/">
    <ARTMAS04>
    <IDOC>
      <xsl:copy-of select="//ARTMAS04/IDOC/EDI_DC40"/>
      <xsl:copy-of select="//ARTMAS04/IDOC/E1BPE1MATHEAD"/>
      <xsl:copy-of select="//ARTMAS04/IDOC/E1BPE1MARART"/>
      <xsl:copy-of select="//ARTMAS04/IDOC/E1BPE1MARAEXTRT"/>
      <xsl:copy-of select="//ARTMAS04/IDOC/E1BPE1MAKTRT"/>
      <xsl:for-each select="//ARTMAS04/IDOC/E1BPE1MARCRT">
        <xsl:if test="(PLANT='D100') or (PLANT='D200') or (PLANT='D300')">
          <xsl:copy-of select="."/>
        </xsl:if>
      </xsl:for-each>
      <xsl:copy-of select="//ARTMAS04/IDOC/E1BPE1MARMRT"/>
      <xsl:copy-of select="//ARTMAS04/IDOC/E1BPE1MEANRT"/>
    </IDOC>
    </ARTMAS04>
    </xsl:template>
    </xsl:stylesheet>
    I have a test IDoc going through this and the first 3 characters of the FIELD1 are "BIK". If I look at the source of the XML file, the problem area looks like this:
    <E1BPE1MARAEXTRT SEGMENT="1">
          <FUNCTION>004</FUNCTION>
          <MATERIAL>000000000000895649</MATERIAL>
          <b><FIELD1>
            BIK</b>      0  0.00 T                                    000000001CARRERA FURY 04 20"     CARRERA FURY 04 20" 2005092420040622    X                    00000000   20031104 00200406140000000000                    0.00 0000000
          </FIELD1>
    You can't really see it above, but there is a carriage return and 8 white spaces before the BIK. Where does this carriage return and white space come from?! Any help would be really appreciated - this is driving me crazy!
    Many thanks,
    Stuart Richards

    Stuart,
    I think I know the cause to your problem. I am not an XSLT programmer but based on searching this forum I found how I can acheive the carriage return at the end of my document. Your xsl statement is as follows:
    <xsl:output method="xml" encoding="UTF-8" omit-xml-declaration="no" indent="yes"/>
    Change the indent value from yes to no. This should remove the carraige return. Hope this works for you.
    I actually need a carriage return and line feed on my document so I am still stuck. All I have acheived is the carraige return.
    Thanks,
    Jim

  • What causes  carriage returns to become page turns in Epu  docs from Pages?

    I converted a long document from pages to Epub. Towards the end a section adds a new page at each carriage return. I tried everything. still can't fix it.

    I think that both your pages have a missing </div> at the end somewhere.
    Opps... that happened when I was stripping down the page to create a working example of my issue. I've fixed the missing div and re-uploaded both pages. The problem is still there.
    Change display: inline; to float: left; and add margin: 0 0 4px 4px; (as shown below)
    I had already tried using float, but something else in the code was forcing the columns to 2 instead of 3.
    Have you used "Apply Source Formatting" ?
    I use that religiously. I'm quite anal about visually clean code.
    Well, I just fixed the problem while replying... funny... I removed the margins from the actual img element (.imageThumb img) and placed it on the div which surrounds the img (.imageThumb). I also reapplied the float. Thanks all for the help - it helped me rethink. But I could have sworn I had once placed the margins on .imageThumb before and it didn't work.
    .imageThumb {
        width: 100px;
        height: 75px;
        display: inline;
        float: left;   
        margin: 0px 10px 10px 0px;
        cursor: pointer;
    .imageThumb img {
        /*margin: 0px 10px 10px 0px;*/

  • Carriage Returns in HTML Code Creating Extra Spaces Between Elements

    I've looked online all over and can't find the solution to my issue. I've found several pages explaining a similar event, but no solution.
    When placing many divs next to each other, I would like to visually view the code as one div per line: (see image) To get this, I have to use hard returns in my code (this method makes editing a lot easier visually). But doing so adds extra spacing between the divs which turns a 3 column set of thumbnails to 2 colums. I can fix this if I adjust the physical margins between the divs, but this can't be the only fix.
    The other fix is if I place the code back to back to back (see image): This makes the div's behave and appear as they should, but now the code is a visual mess because it's all cluttered.
    What I want is to be able to use as many carriage returns in my code and for browsers to disregard these types of line breaks in the code. So essentially, how can I get away from these extra spaces when using hard returns in code?

    I think that both your pages have a missing </div> at the end somewhere.
    Opps... that happened when I was stripping down the page to create a working example of my issue. I've fixed the missing div and re-uploaded both pages. The problem is still there.
    Change display: inline; to float: left; and add margin: 0 0 4px 4px; (as shown below)
    I had already tried using float, but something else in the code was forcing the columns to 2 instead of 3.
    Have you used "Apply Source Formatting" ?
    I use that religiously. I'm quite anal about visually clean code.
    Well, I just fixed the problem while replying... funny... I removed the margins from the actual img element (.imageThumb img) and placed it on the div which surrounds the img (.imageThumb). I also reapplied the float. Thanks all for the help - it helped me rethink. But I could have sworn I had once placed the margins on .imageThumb before and it didn't work.
    .imageThumb {
        width: 100px;
        height: 75px;
        display: inline;
        float: left;   
        margin: 0px 10px 10px 0px;
        cursor: pointer;
    .imageThumb img {
        /*margin: 0px 10px 10px 0px;*/

  • Keep white spaces and carriage returns?

    I'm viewing a column -VARCHAR2(4000)- in a standard report column.
    The column value contains white spaces and carriage returns.
    I put "white-space:pre;" in CSS Style, but it still skips carriage returns...
    What can I do to view white spaces and carriage returns?
    I'm using apex 3.0 and IE 7.
    Saad.

    I'm using apex 3.0 and IE 7.There's your problem...
    IE6 (and, since there don't seem to be any docs saying anything different, presumably IE7) don't support white-space: pre in quirks mode. Don't ask me why - probably in one of MS efforts to "not break the web".
    All the APEX built-in templates are rendered in quirks mode as they don't supply complete DOCTYPEs. If you are using a standard APEX template or a custom template without a complete DOCTYPE declaration you are probably seeing this quirks behaviour.
    It looks like this will change in IE8.

  • Need to remove carriage returns, spaces, etc.

    Hello,
    I am trying to build a string that is on one line,
    1,2,3,4,5,6,7,8,9
    however, I wind up with each number on a separate line.
    1,
    2,
    3,
    4,
    5,
    6,
    7,
    8,
    9
    My code looks like this:
    var xxx = "";
    for (var i=1; i<= nNumWords; i++) {
          global.srchVals[i].name = "Payor Mix";
       global.srchVals[i].mode = 0;
       xxx = i;
       if (i < nNumWords) {
       xxx = xxx + ",";
      //xxx = xxx.replace(/\s+/g,"").trim();
      } else {
       xxx = xxx;
       //xxx = xxx.replace(/\s+/g,"").trim();
          var PMItms = [xxx];
       //console.println(xxx);
    I tried using the following line of code to remove carriage returns and spaces:
       xxx = xxx.replace(/\s+/g,"").trim();
    But it keeps on giving me the following error:
    TypeError: xxx.replace(/\s+/g, "").trim is not a function
    Any help is appreciated.
    Thanks
    Linda

    I just want to make sure I'm approaching this problem the correct way.
    I am trying to build a string that is on one line,
    1,2,3,4,5,6,7,8,9
    however, in the debugging console, I wind up with each number on a separate line.
    1,
    2,
    3,
    4,
    5,
    6,
    7,
    8,
    9
    Will "Trimming" the string correct the issue?
    Thanks
    Linda

  • How to retain carriage return and spaces in a report..

    Hi everyone,
    I have a TEXT AREA where users enter comments in that like
    First record
    Hi           Carriage returns          spaces
    Second  record
    Hi
    carriage returns
    spaces
    Third record
    Hi
         carriage returns
                                 spaces
    Is it possible to retain the carriage returns and spaces when i am displaying the records in a report.
    For carriage returns i replaced  chr(10) with '
    (without the single quotes). I works fine. But how i can i retain the spacesplease give me some suggestions
    Thanks
    phani

    Hi dimitri,
    Thanks for the reply
    For carriage returns i am doing like this replace(column_name,chr(10),'<"br">') (Ignore the double quotes)
    For spaces is there any ASCII code like chr(10) for carriage returns..
    I mean how to identify Number of spaces in database..
    Thanks
    phani
    Message was edited by:
    phani marella

  • Carriage returns are replaced by blank space in SOAP message.

    Hi,
    i am using SOAP request based website. i am using the weblogic webservices. when we sent any SOAP request to the server, if the SOAP xml message contains any carriage returns(new lines) are replaced by a single balnk space.
    i have a requirement where user can enter details in multiple lines. but by the time when it readched server, the SOAP xml message has changed. all the carriage returns are repalced by a blank space.
    Can you please help how to solve this issue.
    Thanks
    subba.

    What are your trying to accomplish?
    I'm thinking you are trying to get a several 'fields' together as a single 'string'. In which case I'd simply concat the fields together like
    SELECT a, b||' '||c ...
    to create a single string with "contents of b space contents of c"
    If you are trying to get one hundred and one blanks, of make a field 101 characters wide with blank padding, then you want to look in the SQL Reference manual for things like lpad, rpad and trim.

  • Carriage Returns and Tabs in XML element

    I have a number of carriage returns and tabs within an xml element. When I take that element I would like it to transform to html in which I am then displaying within a JEditorPane. However, when I do this it is one long string. I have tried the xml:space="preserve" within that element and this still is not working.
    Here is part of the xml with the carriage return line feeds. The element that I am talking about is called pseudocode. You can see it is displayed correctly below.
    Design Document XML : <?xml version="1.0" encoding="ISO-8859-1"?><design-doc><title-page><title>Testing Document</title><class-prepared-for>Lloyd</class-prepared-for><authors>Ben Garbers</authors><date-created>September 23, 2004</date-created></title-page><introduction text="This is the introduction. This is the introduction."/><class-definitions><class-definition class-name="ClassOne" visibility="public" class-complexity="not complex"><global-variables><variable visibility="public" name="VariableOne" object="String" comments="This is a String."/><variable visibility="public" name="VariableTwo" object="Integer" comments="This is an Integer."/></global-variables><methods><method name="MethodOne" synopsis="This will do some things." purpose="public" visibility="public"><input-parms><variable visibility="null" name="firstName" object="String" comments="null"/></input-parms><output-parms><variable visibility="null" name="lastName" object="String" comments="null"/></output-parms><local-variables><variable visibility="null" name="age" object="int" comments="null"/></local-variables><pseudocode xml:space="preserve">/* Ensure that player name exist in the system*/
    if (player =null)
         NullPlayerException;
              if (NOT (isPlayerNameExist(player)))
                   throw PlayerNameNotExistException;
              /* Ensure player name exist in the team already*/
              i ? 1;
              while (i <= length(mPlayers)) {
                   if (mPlayers.mPlayerName != playerName)
                        throw PlayerNameNotExistInTeamException;
    this.mPlayers ? this.mPlayers - player;</pseudocode>
    However, when I do the transformation I get the following with the pseudocode:
    /* Ensure that player name exist in the system*/if (player =null)     NullPlayerException;          if (NOT (isPlayerNameExist(player)))               throw PlayerNameNotExistException;          /* Ensure player name exist in the team already*/          i ? 1;          while (i <= length(mPlayers)) {               if (mPlayers[i].mPlayerName != playerName)                    throw PlayerNameNotExistInTeamException;}this.mPlayers ? this.mPlayers - player;
    It looks like it adds some spaces but no carriage returns or line feeds.
    My transformation code is the following:
         public ParseFile(String xmlString) {
              try {
              //Here we will load the correct style sheet for the message
              //that will be formatted.
              String urlString = "DesignDocument.xsl";
              URL url = this.getClass().getResource(urlString);
              System.out.println("URL to style sheet = " + url.toString());
              String styleSheetName = url.getFile();
              System.out.println("Style sheet name : " + styleSheetName);
              InputStream styleSheetInputStream = this.getClass().getResourceAsStream(urlString);
              //We will than load our SAXParerFactory and parse the message.
              SAXParserFactory SPFactory = SAXParserFactory.newInstance();
              SPFactory.setValidating(true);
              SAXParser sp = SPFactory.newSAXParser();
              XMLReader sax2parser = sp.getXMLReader();
              //NO Validation done on for this because we do NOT have a DTD.
              sax2parser.setFeature(
                   "http://xml.org/sax/features/validation",
                   false);
              sax2parser.setContentHandler(new FileContentHandler());
              //we create a character array of the length of the xml message String
              char[] messageCharacterArray =
                   new char[xmlString.length()];
              // we then put the xml string into the character array.
              messageCharacterArray = xmlString.toCharArray();
              // after this ew end up creating a CharArrayReader that will be used by the Sax
              // parser to parse the xml.
              CharArrayReader xmlCharArrayReader =
                   new CharArrayReader(messageCharacterArray);
              // we put the xml character array within the Input Source which will then be parsed
              // by the Sax2 parser.
              InputSource in = new InputSource(xmlCharArrayReader);
              // Use a Transformer for outputting the message into our formatted xml using
              // the stylesheet defined up in a messages own sxl stylesheet file.
              TransformerFactory tFactory = TransformerFactory.newInstance();
              tFactory.setURIResolver(new BasicURIResolver());
              StreamSource stylesource = new StreamSource(styleSheetInputStream);
              Transformer transformer = tFactory.newTransformer(stylesource);
    //          transformer.setOutputProperty(OutputKeys.INDENT, "yes");
    //          transformer.setOutputProperty("{http://xml.apache.org/xslt}indent-amount", "2");
    //          Properties properties = new Properties();
    //          properties.setProperty("indent", "yes");
    //          properties.setProperty("{http://xml.apache.org/xslt}indent-amount", "2");
    //          transformer.setOutputProperties(properties);
              // We will use a ByteArrayOutputStream to put our transformed xml.
              ByteArrayOutputStream bos = new ByteArrayOutputStream();
              StreamResult result = new StreamResult(bos);
              SAXSource source = new SAXSource(in);
              transformer.transform(source, result);
              String s = bos.toString();
              StringBuffer sb = new StringBuffer();
              //This will make sure the Version Line is not shown.
              BufferedReader br = new BufferedReader(new StringReader(s));
              String line = "";
              while ((line = br.readLine()) != null) {
                        sb.append(line);
              bos.close();
              br.close();
              formattedXmlString = sb.toString();
              System.out.println("--------------------------------");
              System.out.println(formattedXmlString);
              System.out.println("--------------------------------");
              } catch (Exception e) {
                   e.printStackTrace();
    I have been searching and trying to figure this out forever. Any help would be greatly appreciated. Bottom line is that I want carriage returns and tabs to work when transferring from the xml to xsl.

    I get the following line when adding the <pre> tags.
    /* Ensure that player name exist in the system*/if (player =null)     NullPlayerException;          if (NOT (isPlayerNameExist(player)))               throw PlayerNameNotExistException;          /* Ensure player name exist in the team already*/          i ? 1;          while (i <= length(mPlayers)) {               if (mPlayers[i].mPlayerName != playerName)                    throw PlayerNameNotExistInTeamException;}this.mPlayers ? this.mPlayers - player;
    On the screen this is shown on 1 line. It looks like the tabs are working correctly. However, the carriage return, line feeds do not seem to be working. The xml that is pushed into the transformation has the carriage returns and line feeds and is formatted correctly. There has to be something happening when the xsl takes the xml String. When I add <BR></BR> within the xml that doesn't seem to work either.
    I am really sumpted. If you could help DrClap I would really be appreciated.

Maybe you are looking for

  • Since recently, Firefox is displayed in English, and cannot be switched to another language

    I used to use Firefox in a non-English language (apologies but I am not much of a linguist). Since a couple of weeks ago Firefox always displays in English, though under "Tools" / "Languages" the item "German" appears as selected. Switching to Englis

  • Random instant crash when plugging in iPhone as usb tether

    Thought I would share this as I have never seen this happen in all my time using Macs.  I upgraded to Mavericks recently on a DIY Fusion Drive (1.5tb 2008 alu Macbook).  So far all is running well until a glitch tonight that was bizarre.  I plugged i

  • E-recruiting question

    As a recruiter Application Management - Applications - Create activities ... where you can modify? what is the difference between that and ... Requisitions - Candidate Selection - Assignments - Activities I can see where i can change Application Mana

  • How to deploy EJB jar file in Weblogic 8.1

    Hi, I have created the EJB jar file, bearing home,remote,ejb and client class aling with the META-INF folder containing ejb-jar.xml and weblogic-ejb-jar.xml. After all this I am confused where to put this EJB jar file so that the container could depl

  • Pass the ROW value to hyperlink in Webi

    Dear Experts, I have following screniro where we need to pass the each row value to hyperlink to open the another reports, so how this will achieve in Webi, What we have done here, created second reports with following prompts Start Date, End Date, P