We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. Image for the cookie policy date
close icon

Import CSV File


How to importing the double quotes & special char from CSV File?

3 Replies

GM Geetha M Syncfusion Team May 26, 2009 12:36 PM UTC

Hi Guna,

Thank you for your continued interest in Syncfusion products.

You can import a CSV file using the code snippet given below:

IWorkbook workbook = application.Workbooks.Open("Test.csv",",");

The above code imports the complete CSV file.

Please try this and let me know if you have any questions.

Regards,
Geetha


JP Jürgen Pannosch August 25, 2009 01:03 PM UTC

Hi, I have the same problem, I want to import a csv file with xlsio, know my problem is that if i do so, xlsio transforms the values of the column, for example "00000" -> "0" or "00001" -> "1"

So whats wrong?

Sample for my CSV:
00000,Car
00001,House
00002,Garden

The first and the second columns should be recognized as string.

Hope you can help me,

best regards

Juergen


GM Geetha M Syncfusion Team August 26, 2009 07:23 AM UTC

Hi Juergen,

Thank you for your interest in Syncfusion products.

I was able to see that 00000 and 00001 are displayed as 0 and 1 respectively, and the same behavior is visible with MS Excel. Assigning Text format can be possible only with Excel formats and not with CSV, you can check this by saving it in text format (using Excel) and again load it, 00000 will be displayed as 0.

Please let me know if you have any further questions.

Regards,
Geetha

Loader.
Live Chat Icon For mobile
Up arrow icon