Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Can't open xml #82

Closed
EvGeniyLell opened this issue Aug 24, 2019 · 8 comments · Fixed by #99
Closed

Can't open xml #82

EvGeniyLell opened this issue Aug 24, 2019 · 8 comments · Fixed by #99
Assignees
Labels
question Further information is requested

Comments

@EvGeniyLell
Copy link

I download xml from bank and I want convert it to csv
I try last version CoreXLSX, but I can't open file
(numbers and Microsoft excel already can open this file)
is can be opened file like this format, by CoreXLSX?
Screen Shot 2019-08-24 at 23 52 44

@EvGeniyLell
Copy link
Author

failed in this method Archive . scanForEndOfCentralDirectoryRecord
return nil
if potentialDirectoryEndTag == UInt32(endOfCentralDirectoryStructSignature) {
not true for any trying

@MaxDesiatov
Copy link
Collaborator

Hi @EvGeniyLell, sorry for the delayed reply. Unfortunately, I wouldn't be able to fully diagnose the issue without having access to this file. If you run unzip in command-line on it, does that succeed? What's the extension of the file, is that .xlsx or .xls?

@MaxDesiatov MaxDesiatov added the more info needed Not enough details available to proceed label Oct 16, 2019
@EvGeniyLell
Copy link
Author

@MaxDesiatov
Copy link
Collaborator

MaxDesiatov commented Oct 28, 2019

Hi @EvGeniyLell, this file is saved in an old proprietary binary file format called Excel Binary File Format. This can also be easily determined from the .xls extension. The file format that CoreXLSX is able to parse is .xlsx, which is the new open format Office Open XML.

@EvGeniyLell
Copy link
Author

@MaxDesiatov you think with the help of your KIT it will be impossible to parse this file

@MaxDesiatov
Copy link
Collaborator

MaxDesiatov commented Oct 28, 2019

@EvGeniyLell an .xls file as is can't be parsed by CoreXLSX as this is a completely different undocumented format. On the other hand, any version of Office newer than 2007 should allow saving .xls files as .xlsx, I think this should be applicable to Numbers and Google Sheets too. Some loss of formatting data could be possible when you save it as .xlsx format, but that all depends on tools you'd use for conversion. I assume Office would be much better at this than anything else.

When you convert your file to .xlsx, parsing it with CoreXLSX should work, please let me know otherwise.

@MaxDesiatov MaxDesiatov added question Further information is requested and removed more info needed Not enough details available to proceed labels Oct 28, 2019
@EvGeniyLell
Copy link
Author

Sorry, but I am doing automation for this and I need to convert it to CSV
that's why I started looking for a POD that could convert XLS
Thanks for the clarification

@MaxDesiatov
Copy link
Collaborator

MaxDesiatov commented Oct 28, 2019

If you're interested in parsing the old format directly, you could try using something like libxls.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants