https://issues.apache.org/bugzilla/show_bug.cgi?id=45676





--- Comment #5 from Paul Dobson <[EMAIL PROTECTED]>  2008-09-11 15:01:27 PST ---
I did some more testing.  You are right.  It seems to be a problem in the
example code.  Consider the following change to endElement, and characters
methods.  I don't know if this is best way to fix the problem but it seems to
work in my case.

public void endElement(String uri, String localName, String name)
                        throws SAXException {
    // v => contents of a cell
    // Output after we've seen the string contents

    if(nextIsString) {
        idx = Integer.parseInt(lastContents);
        lastContents = sst.getSharedStringAt(idx);
    }
    if(name.equals("v")) {
    System.out.println(lastContents);
    }
     lastContents = "";
}

public void characters(char[] ch, int start, int length)
                                throws SAXException {
    lastContents += new String(ch, start, length);

}


-- 
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to