Note that there are some explanatory texts on larger screens.

plurals
  1. POJava Thread crashing but Swing is still working
    primarykey
    data
    text
    <p>for some cell in XLSX file rt.getFontAtIndex(i) part is just crashing and control is just exiting the function and even calling function. Out Swing windows is still open though. I have no clues why without any exception control is going out of the code.</p> <pre><code> public static String addLinkTagInRichTextForUnderscores(XSSFRichTextString rt) { System.out.print("Was here 1\n"); if(rt.length()==0 || rt == null) { return " "; } String outString = rt.toString(); //String finalString = ""; List&lt;Integer&gt; startIndexListOfUL = new ArrayList&lt;Integer&gt;(); boolean continuing = false; System.out.println(outString +" A "+ rt.length() +"\n\n"); for(int i=1;i&lt;rt.length();i++) { System.out.print("Was here at font "+ i); XSSFFont font = null; try{ //font = rt.getFontAtIndex(i); } catch(Error e){ e.fillInStackTrace(); } System.out.print("Was here too" + rt.getFontAtIndex(i)); if(font!= null) { if(XSSFFont.U_SINGLE == font.getUnderline()) { if(!continuing){ startIndexListOfUL.add(new Integer(i)); continuing = true; } }else{ continuing = false; } } else { //System.out.println("No font " + i); } } System.out.println(startIndexListOfUL); if(startIndexListOfUL.size()==0) { //finalString = outString; return " "; } else { int spacing = 0; for(int i = 0; i&lt;startIndexListOfUL.size(); i++) { outString = insertStringAt(outString,startIndexListOfUL.get(i) + spacing,"&lt;link&gt;"); spacing = spacing + 6; } } //just remove redundant &lt;link&gt; tags outString = outString.replaceAll("(&lt;link&gt;[\\s]?&lt;link&gt;)", "&lt;link&gt;"); //System.out.println("Final &gt;&gt;&gt;&gt; " + outString); return outString; } </code></pre>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload