
java poi
老鼠拧刀满街找猫
微信公众号:Cooking Regex
正则学习分享
展开
-
java poi下载地址
java Poi下载地址原创 2016-04-15 15:30:19 · 1270 阅读 · 0 评论 -
java POI实现Excel单元格数据换行
Workbook wb = new XSSFWorkbook(); //or new HSSFWorkbook(); Sheet sheet = wb.createSheet(); Row row = sheet.createRow(2); Cell cell = row.createCell(2); cell.setCellValue("Us原创 2017-01-12 12:13:08 · 8187 阅读 · 0 评论 -
java POI实现Excel单元格自定义颜色
HSSF HSSFWorkbook wb = new HSSFWorkbook(); HSSFSheet sheet = wb.createSheet(); HSSFRow row = sheet.createRow((short) 0); HSSFCell cell = row.createCell((short) 0); cell.setCellV原创 2017-01-12 11:40:07 · 5538 阅读 · 0 评论 -
java POI设置Excel单元格字体
Workbook wb = new HSSFWorkbook(); Sheet sheet = wb.createSheet("new sheet"); // Create a row and put some cells in it. Rows are 0 based. Row row = sheet.createRow(1); // Crea原创 2017-01-12 11:32:16 · 1921 阅读 · 0 评论 -
java POI 实现Excel合并单元格
Workbook wb = new HSSFWorkbook(); Sheet sheet = wb.createSheet("new sheet"); Row row = sheet.createRow((short) 1); Cell cell = row.createCell((short) 1); cell.setCellValue("This i原创 2017-01-12 11:25:30 · 2619 阅读 · 0 评论 -
java POI实现Excel单元格填充颜色
Workbook wb = new XSSFWorkbook(); Sheet sheet = wb.createSheet("new sheet"); // Create a row and put some cells in it. Rows are 0 based. Row row = sheet.createRow((short) 1);原创 2017-01-12 11:20:37 · 12484 阅读 · 0 评论 -
java POI文本提取Excel
InputStream inp = new FileInputStream("E:\\standarcode\\workbook.xls"); HSSFWorkbook wb = new HSSFWorkbook(new POIFSFileSystem(inp)); ExcelExtractor extractor = new ExcelExtractor(wb);原创 2017-01-12 11:14:22 · 538 阅读 · 0 评论 -
java POI根据单元格的类型获取Excel单元格的内容
/* To get the contents of a cell, you first need to know what kind of cell it is (asking a string cell for its numeric contents will get you a NumberFormatException for example). So, you will want t原创 2017-01-12 10:26:55 · 2525 阅读 · 0 评论 -
java POI设置Excel单元格的边框样式
Workbook wb = new HSSFWorkbook(); Sheet sheet = wb.createSheet("new sheet"); // Create a row and put some cells in it. Rows are 0 based. Row row = sheet.createRow(1); // Create a原创 2017-01-12 10:01:07 · 21186 阅读 · 1 评论 -
java POI实现Excel单元格数据的对齐方式
public static void main(String[] args) throws IOException, InvalidFormatException { Workbook wb = new XSSFWorkbook(); //or new HSSFWorkbook(); Sheet sheet = wb.createSheet(); Row原创 2017-01-12 09:56:03 · 11643 阅读 · 0 评论 -
java POI读取Excel时Files 与 InputStreams两种方式的比较
/** * When opening a workbook, either a .xls HSSFWorkbook, or a .xlsx * XSSFWorkbook, the Workbook can be loaded from either a File or an * InputStream. Using a File object allows for lower m原创 2017-01-11 18:41:24 · 8750 阅读 · 1 评论 -
java POI创建Excel单元格并填充时间数据
//Workbook wb = new XSSFWorkbook(); //FileOutputStream fileOut = new FileOutputStream("E:\\standarcode\\workbook.xlsx"); Workbook wb = new HSSFWorkbook(); FileOutputStream fileOut = new原创 2017-01-11 15:43:03 · 1121 阅读 · 0 评论 -
java POI创建Excel的单元格并填值
//Workbook wb = new XSSFWorkbook(); //FileOutputStream fileOut = new FileOutputStream("E:\\standarcode\\workbook.xlsx"); Workbook wb = new HSSFWorkbook(); FileOutputStream fileOut = new原创 2017-01-11 15:23:44 · 717 阅读 · 0 评论 -
java POI创建Excel文件及Sheet
一、代码 //Workbook wb = new XSSFWorkbook(); //FileOutputStream fileOut = new FileOutputStream("E:\\standarcode\\workbook.xlsx"); Workbook wb = new HSSFWorkbook(); FileOutputStream fi原创 2017-01-11 15:02:55 · 2342 阅读 · 0 评论 -
java读取Excel数据,然后写入到txt文件,并批量保存到oracle数据库中
ReadExcel类:package com.linbilin.readExcel;import java.io.FileInputStream;import java.io.FileWriter;import java.sql.Connection;import java.util.ArrayList;import java.util.LinkedHashMap;import原创 2016-05-04 17:00:03 · 2140 阅读 · 0 评论 -
java poi读取Excel里面含有公式的单元格的值
public static String getCellValue(Cell cell) { int cellType = cell.getCellType(); String cellValue = ""; switch (cellType) { case HSSFCell.CELL_TYPE_NUMERIC: cellValue = String.valueOf(cell原创 2016-05-04 14:50:42 · 14903 阅读 · 4 评论 -
java POI实现Excel单元格数据格式化
Workbook wb = new HSSFWorkbook(); Sheet sheet = wb.createSheet("format sheet"); CellStyle style; DataFormat format = wb.createDataFormat(); Row row; Cell cell; shor原创 2017-01-12 12:17:47 · 1822 阅读 · 0 评论