I have a string that has values seperated by commas. Is there a way in C# to get those values or has anyone made an easy function that will do this for me?
The string looks like this
value1,value2,value3,value4 and so on.
I'd like to have each value so that I can do other functions based on the value.
Seperate values in a string
Started by Chan, Jul 17 2006 02:48 PM
4 replies to this topic
#1
Posted 17 July 2006 - 02:48 PM
|
|
|
#2
Posted 17 July 2006 - 03:25 PM
Go to google and search for "CSV C#"
CSV stands for comma seperated values and yes there are numerous methods for dealing with them, I suggested the google search because I am unsure what you wish to do with these values...hopefully this helps.
CSV stands for comma seperated values and yes there are numerous methods for dealing with them, I suggested the google search because I am unsure what you wish to do with these values...hopefully this helps.
#3
Posted 18 July 2006 - 03:04 AM
System.String.Split is what you want.
#4
Posted 24 July 2006 - 06:00 PM
split is easiest as long as their is a delimiter (space, comma, colon, etc.).
#5
Posted 25 July 2006 - 06:17 AM
I was trying to write my own "split" function until I read this. It didn't work anyway. Thanks.


Sign In
Create Account


Back to top









