Skip to main content

Convert Array to Comma Seprated String

If you have an array of Integers and want to convert it into comma separated string. here is the following code

  
  //integer Array
  int[] arr = new int[5] {1,2,3,4,5};
  
  string arrvalue= string.Join(",", arr); 
  

results will be arrvalue= "1,2,3,4,5"

Comments

Popular posts from this blog