Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP

Comparing changes

Choose two branches to see what's changed or to start a new pull request. If you need to, you can also compare across forks.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also compare across forks.
  • 2 commits
  • 2 files changed
  • 0 commit comments
  • 1 contributor
Showing with 10 additions and 8 deletions.
  1. +8 −8 lib/NodeExcel.js
  2. +2 −0  lib/Worksheet.js
View
16 lib/NodeExcel.js
@@ -128,7 +128,7 @@ module.exports.create = function () {
}
function setIndexByName(sheetName, newIndex) {
- var
+ var
oldIndex = getIndex(getSheetByName(sheetName)),
sheet = worksheetCollection.splice(oldIndex, 1);
@@ -137,16 +137,21 @@ module.exports.create = function () {
}
function getSheetNames() {
- var
+ var
sheetNames = [],
worksheetCount = getSheetCount();
-
+
for (var i = 0; i < worksheetCount; i++) {
sheetNames.push(getSheet(i).getTitle());
}
return sheetNames;
}
+ function addCellXf(style) {
+ cellXfCollection.push(style);
+ style.setIndex(cellXfCollection.length - 1);
+ }
+
function addExternalSheet(newSheet, sheetIndex) {
if(!getSheetByName(newSheet.getTitle())) {
throw new Error('Workbook already contains a worksheet named' + newSheet.getTitle() + '. Rename the external sheet first.');
@@ -248,11 +253,6 @@ module.exports.create = function () {
throw new Error('No default style found for this workbook');
}
- function addCellXf(style) {
- cellXfCollection.push(style);
- style.setIndex(cellXfCollection.length - 1);
- }
-
function removeCellXfByIndex(index) {
if (index > cellXfCollection.length - 1) {
throw new Error('CellXf index is out of bounds.');
View
2  lib/Worksheet.js
@@ -778,6 +778,8 @@ module.exports.create = function (excel, title) {
chartCollection = {};
cellCollection = cachedObjectStorageFactory.getInstance(self);
+
+ setSheetState(constants.sheetState.visible);
}
self.disconnectCells = disconnectCells;

No commit comments for this range

Something went wrong with that request. Please try again.