Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

234
Views
Arabic characters displayed as symbols in CSV file. C# .NET
var result = await profileManager.GetCSVAsByteResults(searchOptions); // return array of bytes
            
if (result == null || result.Length == 0)
{
    return NotFound();
}
var finalResult = Encoding.UTF8.GetPreamble().Concat(result).ToArray();
return File(finalResult, "text/csv", $"UserProfiles.{DateTime.Now:yyyy.MM.dd.HH.mm.ss}.csv");

GetCSVAsByteResults method

public static byte[] GetCSVAsByteResults<T>(IEnumerable<T> data)
        {
            using (var memory = new MemoryStream())
            using (var writer = new StreamWriter(memory, new UTF8Encoding(true)))
            using (var csvWriter = new CsvWriter(writer))
            {
                csvWriter.WriteRecords<T>(data);
                writer.Flush();
                var result = memory.ToArray();
                return result;
            }
        }

the CSV file contains Arabic letters but they are displayed as symbols I tried what I find while searching on the internet and still have the same problem.

over 4 years ago · Santiago Trujillo
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!