FIXED - task 574: create safe sheet names for Excel export - patch from jd@tekii.com.ar
http://code.google.com/p/google-refine/issues/detail?id=574 git-svn-id: http://google-refine.googlecode.com/svn/trunk@2582 7d457c2a-affb-35e4-300a-418c747d4874
This commit is contained in:
parent
c003ef42a2
commit
4d48741ce0
@ -47,6 +47,7 @@ import org.apache.poi.ss.usermodel.CellStyle;
|
||||
import org.apache.poi.ss.usermodel.Row;
|
||||
import org.apache.poi.ss.usermodel.Sheet;
|
||||
import org.apache.poi.ss.usermodel.Workbook;
|
||||
import org.apache.poi.ss.util.WorkbookUtil;
|
||||
import org.apache.poi.xssf.usermodel.XSSFWorkbook;
|
||||
import org.json.JSONObject;
|
||||
|
||||
@ -80,7 +81,9 @@ public class XlsExporter implements StreamExporter {
|
||||
@Override
|
||||
public void startFile(JSONObject options) {
|
||||
s = wb.createSheet();
|
||||
wb.setSheetName(0, ProjectManager.singleton.getProjectMetadata(project.id).getName());
|
||||
String sheetName = WorkbookUtil.createSafeSheetName(
|
||||
ProjectManager.singleton.getProjectMetadata(project.id).getName());
|
||||
wb.setSheetName(0, sheetName);
|
||||
|
||||
dateStyle = wb.createCellStyle();
|
||||
dateStyle.setDataFormat(
|
||||
|
Loading…
Reference in New Issue
Block a user