03-15-2019 03:44 AM
I'm currently developing an application with a .Net interface for Excel. I really don’t like to use the NI LV toolkit because of the legacy ActiveX interface. Writing to Excel works just fine, but reading from a spreadsheet fails at the point where I am trying to convert the values from the .Net reference to LV variant. Does anybody have a working solution for the problem?
I’ve attached my current status.
Solved! Go to Solution.
03-15-2019 05:49 AM
This thread indicates that 2D-array is not handled by ".NET object to Variant", and proposes the solution of reading cell by cell.
03-15-2019 06:01 AM
I like the EPPlus .NET DLL
https://github.com/JanKallman/EPPlus
You don't have need Excel to be installed !
03-15-2019 06:57 AM
This is true. If using the workaround which is proposed, by reading cell by cell with nested loops it is working perfectly.
Thanks a lot!
03-18-2019 07:58 PM
@EWiebe wrote:
I like the EPPlus .NET DLL
https://github.com/JanKallman/EPPlus
You don't have need Excel to be installed !
Do you have an example of using this Library in LabVIEW?
03-19-2019 12:50 AM
Is this library thread safe? In my use case it may occur that two excel files are created at the same time.
03-19-2019 02:56 AM - edited 03-19-2019 02:57 AM
I found a link:
https://forums.ni.com/t5/LabVIEW/Create-spreadsheet-using-Open-XML-SDK-Net-with-Labview/td-p/3235208
I've just tried it and it is really easy to use.
03-21-2019 08:28 AM
03-22-2019 04:48 AM - edited 03-22-2019 04:49 AM
I've done this as well and I got a reply yesterday. It is filed under CAR 732638.
07-19-2023 04:28 AM
Hi everyone,
The above method is the only one working ok found by me so far. But for large files it takes too much to load them. I fell asleep near the computer for files with 10 000 rows ...
The next one, using Value2 property is still not working.
Has anyone else found a workaround for this matter?
Thanks,
Daniel