on 05-07-2020 5:13 PM
Hi,
I'm trying to automate the import of data from a CSV file into Excel and do some manipulation during the import (replace values, remove columns,...). Is there a good way doing this? I couldn't find any function within the excel SDK and it's quite hard to do all the steps using UIAutomation or WIN. I need some pre-processing on the data stored on the CSV file and excel was till now the best application.
Any ideas how to import CSV data into excel?
excel-importdatafromcsv.jpgexcel-importdatafromcsv-replacevalues.jpg
Adrian
Hi Adrian,
Actually, there is no method allowing the import of a CSV file.
What you can do is try to do it using UIAutomation, or try to import the CSV file into the sheet using an ActiveX object.
Here is a blog post about doing queries to an Excel file using ActiveX object. It can be useful:
https://blogs.sap.com/2020/02/05/how-to-read-data-from-worksheet-using-query/
Regards,
Baptiste
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
84 | |
10 | |
10 | |
9 | |
7 | |
7 | |
6 | |
5 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.