function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
krishna casukhela 15krishna casukhela 15 

get element of javascript array

I have an javascript array in lightning component controller.
var networkIds=[];
after some logic I have as follows inside the array "NetworkID":"11320"
I want to extract the number "11320" and then store it in attribute of type string..
I am doing as follows: var networkid=networkIds[0].split(':');
But I am getting an error
can any one pls let me know.

thanks
Krishna
AbhishekAbhishek (Salesforce Developers) 
Your query is already answered here (https://salesforce.stackexchange.com/questions/321829/array-issue-in-javascript).

Kindly let me know if it helps you and close your query by marking it as solved so that it can help others in the future.

Thanks.