解決 The type CellRangeAddress is deprecated的問題

有時在使用JAVA POI 操作Excel合併單元格的時候,會遇到The type CellRangeAddress is deprecated這樣的問題.
而出現這個問題的原因是包路徑過時.
只需要將

import org.apache.poi.hssf.util.CellRangeAddress;

改成

import org.apache.poi.ss.util.CellRangeAddress;

問題就解決了

發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章