Append Comma to String Value

You are looping on value_dt_str which is invalid in your case as this would store single character in loop variable item.
You should use for each row in datatable and loop over value_dt, inside loop assign respective columns current value to a variable say temp_str; e.g. temp_str = CurrentRow(“column name or index”).

then you can use insert function on temp_str;

temp_str.ToString.Insert(cint(temp_str.ToString.Length)-2,”,”).ToString)

1 Like