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. (Last updated on: November 16, 2018).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

CSV format - Remove Double Quotes

Thread ID:





76801 Sep 24,2008 04:36 PM UTC Sep 25,2008 12:38 PM UTC ASP.NET Web Forms (Classic) 1
Tags: XlsIO
Vidya Jayakumar
Asked On September 24, 2008 04:36 PM UTC


I am Saving data coming from database -> into a Datatable then importing into a
worksheet and saving it in CSV format.
I am actually saving the file in MapPath first and opening a dialog box and
having user save it whereever they want to.

the code looks like this:-

Protected Sub btn_Import_Click(ByVal sender As Object, ByVal e As EventArgs) Handles btn_Import.Click
excelEngine = New ExcelEngine()
appl = excelEngine.Excel
workbook = appl.Workbooks.Create(3)
Dim strpath1 As String = Server.MapPath("Import")
Method call is very simple in selecting 4 columns from a sql table and out of it 3 are varchar columns and one is int-:Comments
Dim mycsvdatatable As DataTable = GetDataToCSVFile()
sheet = workbook.Worksheets(1)
sheet.ImportDataTable(mycsvdatatable, False, 1, 1)
sheet.SaveAs(strpath1 & "\" & "Sample.csv", ",", Encoding.ASCII)
Comments:-Opens a dialog box to

Response.Redirect("~\Import\" & "Sample.csv", False)
End Sub

Attached CSV file has Text/varchar columns (Columns B,C,D in attached file) in Quotes.As i mentioned above 3 columns they are enclosed in Double Quotes in CSV file. May i know Why? Is there any way to remove them via Sync's save as() method

In another example for CSV file i got from your forums:-
I see the format to save the file is different- there is no encoding parameter?

Are the Double quotes due to saving format as Encoding.ASCII?



Geetha M [Syncfusion]
Replied On September 25, 2008 12:38 PM UTC

Hi Vidya,

Thank you for your continued interest in Syncfusion products.

I am afraid that I am not able to reproduce the problem. You can get the test sample I created based on the above code snippets in the below link:


Please try running the above sample and let me know if you are able to see the problem at your end.

Also, I am able to see the problem only when I am not setting the Encoding as ASCII. So, could you please let me know the regional settings of your environment?



This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

Please sign in to access our forum

This page will automatically be redirected to the sign-in page in 10 seconds.

Warning Icon You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.Close Icon