mac下载的excel如果带有超链接,url被转义问题

注释的代码是file开头的,这种链接在mac系统进行跳转url会转义 hyperlink
还有一种就是http这种就可以正常跳转了。

String sLink = basePath + "/detail/init2?formerQuery="+EncryptUtils.encodeUrl(formerQuery) + "&local="+locale; //hyperlink.setAddress(sLink); String url = (Utils.isNull(locale) || "zh".equals(locale)) ? "跳转" : "View in incopat\r\n"; _cell.setCellFormula("HYPERLINK(\"" + sLink+ "\",\"" + "跳转 "+ patent.getPn()+ "\")"); _cell.setCellValue(url + pn.toUpperCase() + ""); //_cell.setHyperlink(hyperlink);

 

posted on 2018-09-21 15:07  boboxing2017  阅读(957)  评论(0编辑  收藏  举报