我正在尝试将JSON数据转换为CSV和XLSX,并有两个按钮,允许我下载CSV和XLSX表单。CSV按钮工作,但XLSX按钮不工作。
我尝试过很多事情,例如:
var filename = "RawData.xlsx" alasql('SELECT * INTO XLSX("' + filename + '",{headers:true}) FROM ?', [$scope.data]);
var filename = "RawData.xls" alasql('SELECT * INTO XLS("
我对web编程很陌生,我正在做的第一个项目是一个网站,它允许用户从Excel文件(每天更新)中看到信息。在Youtube教程和这个库的帮助下,我开始将Excel文件转换为JSON。
我有我想要转换为对象的信息,但我不知道如何使用它在网站中显示表格。有什么建议吗?
这是我目前的代码:
/* set up XMLHttpRequest */
var url = "Teste.xlsx";
var oReq = new XMLHttpRequest();
oReq.open("GET", url, true);
oReq.responseType
我正在尝试使用XLSX读取我的excel文件。将其抛出错误读入“损坏的zip :无法找到中心目录的末尾”时
这是我要犯的错误
Error: Corrupted zip : can't find end of central directory
at Object.ZipEntries.readEndOfCentral (/Users/.../node_modules/xlsx/jszip.js:2087:27)
at Object.ZipEntries.load (/Users/.../node_modules/xlsx/jszip.js:2104:18
我正在使用当前构建的Wijmo (5.20172.359)在一个角2项目(角4.4.4,TypeScript 2.5.3)。但是,我一直使用的所有东西(FlexGrid,FlexPie,FlexCharts)都很好.
我正在尝试集成Excel功能,并使用与构建一起下载的TS/Angular2 2示例中包含的ExcelImportExport项目,并在构建中得到以下错误:
Uncaught TypeError: window.require is not a function
at Object../node_modules/wijmo/wijmo.xlsx.js (app.js:862
我在我的解决方案中生成.xlsx文档并将它们发送给用户,当使用js-xlsx解析它们时,它们有零个单元格,这可以通过使用Excel打开生成的.xlsx并保存它们来解决。
我希望能够直接使用js-xlsx解析我生成的.xlsx文档。
保存到.xlsx的代码:
var ms = new MemoryStream();
workbook.SaveAs(ms);
ms.Seek(0, SeekOrigin.Begin);
return ms;var ms = new MemoryStream();
使用js-xlsx打开.xlsx的代码:
我一直在尝试使用XLSX lib创建一个.xlsx文件。但是当我试图写一个XLSX文件时,我得到了这个错误信息:
TypeError: n.t.match is not a function
at Ps (xlsx.full.min.js:14)
at Jd (xlsx.full.min.js:18)
at Sv (xlsx.full.min.js:21)
at Fv (xlsx.full.min.js:21)
at Object.Uv [as write] (xlsx.full.min.js:21)
at n.scope.download (excelExport.js:100)
在我的Wijmo项目中,我在Angular 4上使用wijmo.xlsx和JSZip遇到了麻烦。wijmo.xlsx需要JSZip作为依赖项。
如下所示,当我在TypeScript文件中导入JSZip时,它显示了JSZip的错误。
import * as JSZip from 'jszip';
我使用npm install jszip --save安装了JSZip,但它不起作用。
我这次安装了@types/jszip,错误消失了。但是当我尝试使用JSZip时,它显示了以下错误:
(index):55 (SystemJS) window.require is not a func
堆栈跟踪如下所示。
Test suite failed to run
ReferenceError: cptable is not defined
1 | import React, { Component } from 'react';
> 2 | import ReactExport from 'react-export-excel';
| ^
at cptable (node_modules/react-export-excel/node_modules/xlsx/xlsx.js:10:37)
at Object.<a
我试图使用xlsx (v0.8.0)解析一个文件,该文件是通过stdin管道传输的。
以下代码:
const data = fs.readFileSync('/dev/stdin').toString();
wb = xlsx.read(data, {type: 'binary'});
当我将文件(在mac上)作为cat foo.xlsx \节点test.js传输时失败:
> throw new Error("Corrupted zip : can't find end of central directo
我在Angular 4和SystemJS ()上使用这个种子项目
并想用SheetJS导出Excel文件。我按照说明,可以导入xlsx很好,但是导出文件的时候它不断的返回错误:
XLSX.utils.aoa_to_sheet is not a function
我已经向project.config.ts添加了
...
{
name: 'xlsx',
// Path to the package's bundle
path: 'node_modules/xlsx/dist',
packageMeta: {
d
我正在尝试读取一个excel文件的一个防火墙功能。我选择使用库'xlsx‘()。我用npm install xlsx安装了库,它工作得很好,并将库添加到package.json依赖项中作为"xlsx": "^0.15.5"。我需要使用const XLSX = require('xlsx');的firebase函数中的模块,但随后收到以下错误:
Function failed on loading user code. Error message: Code in file index.js can't be loaded.
Did
我试图使用URL从jira服务器下载一个文件,但我得到了一个错误。如何在代码中包含证书以进行验证?
错误:
Error: unable to verify the first certificate in nodejs
at Error (native)
at TLSSocket.<anonymous> (_tls_wrap.js:929:36)
at TLSSocket.emit (events.js:104:17)
at TLSSocket._finishInit (_tls_wrap.js:460:8)
我的Nodejs代码:
var https =
我收到了这个错误,不知道该怎么做。我以前没有使用过node_modules,所以有帮助是很好的。
我的文件:
我使用的是test.js文件代码:
const XLSX = fetch('xlsx')
// array of objects to save in Excel
let binary_univers = [{'name': 'Hi','value':1},{'name':'Bye','value':0}]
console.log(binary_univers
我的R代码目前涉及循环遍历一组.xlsm文件,通过function转换每个工作表中的数据,然后将文件输出为一组.xlsx文件。假设我的Filelist只包含2个文件,即Filelist = c("aaa.xlsm", "bbb.xlsm"),我的当前代码将输出文件名分别为"aaa.xlsm.xlsx“和"bbb.xlsm.xlsx”的.xlsx文件。 Filelist <- list.files(pattern = ".xlsm$") #extract list of files from folder that end