CSV string handling
- by Christian Hagelid
Typical way of creating a CSV string (pseudocode):
create a CSV container object (like a StringBuilder in C#)
Loop through the strings you want to add appending a comma after each one
After the loop, remove that last superfluous comma.
Code sample:
public string ReturnAsCSV(ContactList contactList)
{
StringBuilder sb = new…