Hi, I want to iterate through comma separated string, want to get each element but in vein, what I've in my comma separated string is as below, and how i'm trying to get is also mentioned,
Result I'm getting is on each iteration is like, it alerts each digit like 0 then 9 then 3 then decimal point (.) and so on.
I want to get 093.33 on first iteration , 789.23 on 2nd iteration and so on...
I want to get 093.33 on first iteration , 789.23 on 2nd iteration and so on...
- var CommaStr = "093.33, 789.23, 003,21, 123.43, 188.02";
- for (var j = 0; i < CommaStr .split(',').length; j++) {
- alert(CommaStr[j]);
- }
3 Replies
Know the answer? Post it — somebody with the same question will find it here.
Sign in to answer this question
It is the same account you read, post and publish with — and you will come straight back to this page.

Jignesh KumarPosted Dec 18, 2019, 10:07 PM
Rameez JavedPosted Dec 18, 2019, 5:41 AM
Amit MohantyPosted Dec 18, 2019, 4:36 AM
"));