0.0.7 • Published 8 years ago

dockin v0.0.7

Weekly downloads
2
License
MIT
Repository
github
Last release
8 years ago

Build Status

intuitive xlsx spreadsheet parser wrapper

'use strict';
'use strict';
const indoc = require('./index.js');
const Document = indoc.Document;
const path = require('path');
const _ = require('lodash');

let doc = Document(path.resolve(__dirname, 'file.xlsm'));
let sheet = doc.getSheet('Controls Matrix');
console.log(sheet.getCell('A', 3).value());
let rows = sheet.getRows();
console.log(rows.length, rows[0].length);
//console.log(sheet.getValuesOfRows());
//console.log(_.keys(sheet));
let strategy = sheet.findRow('Control Titel', 'It Strategie');
let columnTitles = sheet.getTitles();
//console.log(columnTitles);
console.log(strategy.getCellByTitle('Control Titel').value());

_.forEach(columnTitles, (title) => {
  console.log(`${title}:`, strategy.getCellByTitle(title).value());
});

console.log(sheet.findRows('Control Titel', 'SAP').length);

License

MIT © Andre Stehle

0.0.7

8 years ago

0.0.6

8 years ago

0.0.5

8 years ago

0.0.4

8 years ago

0.0.3

8 years ago

0.0.2

8 years ago

0.0.1

8 years ago