renebigot / XlsxReaderWriter

XlsxReaderWriter is an Objective-C library for iPhone / iPad and Mac. It parses and writes MS Excel XLSX files.
MIT License
437 stars 121 forks source link

Error saving Spreadsheet #18

Closed khose closed 8 years ago

khose commented 8 years ago

Hi! First of all, thanks for building this awesome library :+1:

I'm using it to fill an existing xlsx file (created with Numbers app, exported to xlsx). After writing the data, I save it using

NSString *fullPath = [[NSSearchPathForDirectoriesInDomains(NSDocumentDirectory, NSUserDomainMask, YES) lastObject] stringByAppendingPathComponent:@"workbookCopy.xlsx"]; [self.spreadsheet saveAs:fullPath];

After that, I use the XCode option to download the container directly from the device. Once I do it, I can't find the xlsx inside the package.

I'm using an iPad 2 mini, iOS 9.2.

If you need anything to get more information, please let me know. I will provide whatever is needed.

Thanks!

khose commented 8 years ago

The spreadsheet object was released somehow, and that was causing the failure.

My fault :D . Closing...

renebigot commented 8 years ago

Oh, thanks ! I was trying to solve this. Happy to know that its not the library that was causing the problem. I'm also even more happy to learn that you've solve your problem.

Thank for using this library ;)

CuSoft commented 8 years ago

When the spreadsheet was released, where did it happen and how did you retain it? I am attempting to save a spreadsheet and get "array cannot be nil" returned - might be having the same issue?

mdeandreis commented 8 years ago

@CuSoft, I have the same issue using swift. Any idea?

Terminating app due to uncaught exception 'NSInvalidArgumentException', reason: '*\ -[__NSArrayM insertObject:atIndex:]: object cannot be nil'


Thanks!