https://bz.apache.org/bugzilla/show_bug.cgi?id=58315
Bug ID: 58315 Summary: NullPointerException by XSSFRichTextString.getFontAtIndex Product: POI Version: 3.12-FINAL Hardware: PC Status: NEW Severity: normal Priority: P2 Component: XSSF Assignee: dev@poi.apache.org Reporter: florian.linderma...@lfst.bayern.de Created attachment 33058 --> https://bz.apache.org/bugzilla/attachment.cgi?id=33058&action=edit Sample Project To Show the bug Hello, i need to find striked out Characters in a Cell. In my Cell is a String containing "320 338 350". " 388" is striked out and has a blue color. My code breaks when trying to retriev the Font(richText.getFontAtIndex(i)) with i==2. At i==2 the Font changes from a the rich text font(getFontAtIndex is returning a Font) to the cell font(getFontAtIndex should return null). for (int i = richText.length() - 1; i >= 0; i--) { Font f = richText.getFontAtIndex(i); if (f != null && f.getStrikeout()) { tmpCellContent.deleteCharAt(i); } } I attached a sample project. Run the unit test -- You are receiving this mail because: You are the assignee for the bug. --------------------------------------------------------------------- To unsubscribe, e-mail: dev-unsubscr...@poi.apache.org For additional commands, e-mail: dev-h...@poi.apache.org