Update XLS exporter to Apache POI 4.0.1
This commit is contained in:
parent
d0eff4c5a8
commit
4984837c9f
@ -39,7 +39,8 @@ import java.time.OffsetDateTime;
|
|||||||
import java.util.List;
|
import java.util.List;
|
||||||
import java.util.Properties;
|
import java.util.Properties;
|
||||||
|
|
||||||
import org.apache.poi.hssf.usermodel.HSSFHyperlink;
|
import org.apache.poi.common.usermodel.Hyperlink;
|
||||||
|
import org.apache.poi.common.usermodel.HyperlinkType;
|
||||||
import org.apache.poi.hssf.usermodel.HSSFWorkbook;
|
import org.apache.poi.hssf.usermodel.HSSFWorkbook;
|
||||||
import org.apache.poi.ss.usermodel.Cell;
|
import org.apache.poi.ss.usermodel.Cell;
|
||||||
import org.apache.poi.ss.usermodel.CellStyle;
|
import org.apache.poi.ss.usermodel.CellStyle;
|
||||||
@ -126,7 +127,7 @@ public class XlsExporter implements StreamExporter {
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (cellData.link != null) {
|
if (cellData.link != null) {
|
||||||
HSSFHyperlink hl = new HSSFHyperlink(HSSFHyperlink.LINK_URL);
|
Hyperlink hl = wb.getCreationHelper().createHyperlink(HyperlinkType.URL);
|
||||||
hl.setLabel(cellData.text);
|
hl.setLabel(cellData.text);
|
||||||
hl.setAddress(cellData.link);
|
hl.setAddress(cellData.link);
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user