Search
 
SCRIPT & CODE EXAMPLE
 

CSHARP

how to save a dictionary as a csv file in c#

String csv = String.Join(
    Environment.NewLine,
    data.Select(d => $"{d.Key};{d.Value};")
);
System.IO.File.WriteAllText(pathToCsv, csv);
Comment

PREVIOUS NEXT
Code Example
Csharp :: raycasthit unity 
Csharp :: single line and multiline comments in c 
Csharp :: read file using c# 
Csharp :: c# empty list 
Csharp :: list search c# 
Csharp :: get key value from object c# 
Csharp :: how to set picturebox width with form width in c# 
Csharp :: c# dictionary keys to list 
Csharp :: hcf of numbers 
Csharp :: unity call function on update once per second 
Csharp :: how c# connection 
Csharp :: unity setparent 
Csharp :: c# object list attribute to string 
Csharp :: unity get center of object 
Csharp :: unity class 
Csharp :: c# windows forms open directory in explorer 
Csharp :: c# get type of class 
Csharp :: datetime month name 
Csharp :: system.net.mail send html message 
Csharp :: asp.net response.redirect new tab 
Csharp :: c# array display 
Csharp :: if set active == false 
Csharp :: cs string to enum 
Csharp :: c# xml get root attributes 
Csharp :: change sprite color unity 
Csharp :: how to get an arrays length in c# 
Csharp :: c# how to call methods from another class 
Csharp :: c# convert datetime to year & month 
Csharp :: append an array in c# 
Csharp :: C# unit test exception using attribrute 
ADD CONTENT
Topic
Content
Source link
Name
5+5 =