Questions tagged [xlsx]

xlsx is the file extension for files created using the default format of Microsoft Excel 2007 or higher.

xlsx is the file extension for files created using the default format of Microsoft Excel 2007 or higher. This is the Microsoft Office Open XML SpreadsheetML format. This format is based around a zipped collection of eXtensible Markup Language (XML) files. Microsoft Office Open XML SpreadsheetML is mostly standardized in ECMA 376 and ISO 29500.

Resources

3538 questions
397
votes
13 answers

Using Pandas to pd.read_excel() for multiple worksheets of the same workbook

I have a large spreadsheet file (.xlsx) that I'm processing using python pandas. It happens that I need data from two tabs (sheets) in that large file. One of the tabs has a ton of data and the other is just a few square cells. When I use…
HaPsantran
  • 5,581
  • 6
  • 24
  • 39
367
votes
12 answers

Convert xlsx to csv in Linux with command line

I'm looking for a way to convert xlsx files to csv files on Linux. I do not want to use PHP/Perl or anything like that since I'm looking at processing several millions of lines, so I need something quick. I found a program on the Ubuntu repos called…
user1390150
  • 3,679
  • 3
  • 14
  • 3
168
votes
25 answers

Excel "External table is not in the expected format."

I'm trying to read an Excel (xlsx) file using the code shown below. I get an "External table is not in the expected format." error unless I have the file already open in Excel. In other words, I have to open the file in Excel first before I can read…
Sisiutl
  • 4,915
  • 8
  • 41
  • 54
124
votes
13 answers

Easy way to export multiple data.frame to multiple Excel worksheets

I am surprised to find that there is no easy way to export multiple data.frame to multiple worksheets of an Excel file? I tried xlsx package, seems it can only write to one sheet (override old sheet); I also tried WriteXLS package, but it gives me…
Ogre Magi
  • 1,445
  • 3
  • 13
  • 14
100
votes
16 answers

Importing Excel files into R, xlsx or xls

Please can someone help me on the best way to import an excel 2007 (.xlsx) file into R. I have tried several methods and none seems to work. I have upgraded to 2.13.1, windows XP, xlsx 0.3.0, I don't know why the error keeps coming up. I…
nolyugo
  • 1,451
  • 3
  • 12
  • 12
94
votes
6 answers

Handling java.lang.OutOfMemoryError when writing to Excel from R

The xlsx package can be used to read and write Excel spreadsheets from R. Unfortunately, even for moderately large spreadsheets, java.lang.OutOfMemoryError can occur. In particular, Error in .jcall("RJavaTools", "Ljava/lang/Object;",…
Richie Cotton
  • 118,240
  • 47
  • 247
  • 360
82
votes
8 answers

Importing a big xlsx file into R?

I'm wondering if anyone knows of a way to import data from a "big" xlsx file (~20Mb). I tried to use xlsx and XLConnect libraries. Unfortunately, both use rJava and I always obtain the same error: > library(XLConnect) > wb <-…
user2722443
  • 821
  • 1
  • 7
  • 4
65
votes
9 answers

Convert xlsx file to csv using batch

How do you convert multiple xlsx files to csv files with a batch script?
Ankur
  • 2,321
  • 3
  • 17
  • 7
63
votes
8 answers

Python convert csv to xlsx

In this post there is a Python example to convert from csv to xls. However, my file has more than 65536 rows so xls does not work. If I name the file xlsx it doesnt make a difference. Is there a Python package to convert to xlsx?
user670186
  • 2,588
  • 6
  • 37
  • 55
62
votes
8 answers

Parse XLSX with Node and create json

Ok so I found this really well documented node_module called js-xlsx Question: How can I parse an xlsx to output json? Here is what the excel sheet looks like: In the end the json should look like this: [ { "id": 1, "Headline": "Team:…
Armeen Moon
  • 18,061
  • 35
  • 120
  • 233
56
votes
7 answers

How to set cell width when export .xlsx files with js-xlsx

I am trying to set a fixed column/cell width to my exported excel files with js-xlsx. EDIT: Here is the source of js-xlsx: https://github.com/SheetJS/js-xlsx
jgabrielfaria
  • 1,543
  • 3
  • 15
  • 19
53
votes
2 answers

Looking for a clear description of Excel's .xlsx XML format

Microsoft Excel's ".xlsx" files are zip files that each contain a set of files. Could someone please provide a link that concisely describes the full structure/syntax/markup/format of the embedded .xml files (the headers are less interesting)? For…
none
  • 4,669
  • 14
  • 62
  • 102
53
votes
4 answers

How to properly assemble a valid xlsx file from its internal sub-components?

I'm trying to create an xlsx file programmatically on iOS. Since the internal data of xlsx files is basically stored in separate xml files, I tried to recreate xlsx structure with all its files and subdirectories, compress them into a zip file and…
nick130586
  • 801
  • 1
  • 9
  • 21
49
votes
10 answers

Setting styles in Openpyxl

I need advice on setting styles in Openpyxl. I see that the NumberFormat of a cell can be set, but I also require setting of font colors and attributes (bold etc). There is a style.py class but it seems I can't set the style attribute of a cell, and…
Nelson Shaw
  • 1,103
  • 2
  • 10
  • 10
49
votes
9 answers

How to save .xlsx data to file as a blob

I have a similar question to this question(Javascript: Exporting large text/csv file crashes Google Chrome): I am trying to save the data created by excelbuilder.js's EB.createFile() function. If I put the file data as the href attribute value of a…
gm2008
  • 4,245
  • 1
  • 36
  • 38
1
2 3
99 100