I have this JSON string assigned to a variable.
<script>var Countries = {"Countries": [
{"locname":"Argentina","locCountry":"AR","ProductCount":"8","BreweryCount":"2"},
{"locname":"Austria","locCountry":"AT","ProductCount":"5","BreweryCount":"2"},
{"locname":"Belgium","locCountry":"BE","ProductCount":"19","BreweryCount":"4"},
{"locname":"Brazil","locCountry":"BR","ProductCount":"23","BreweryCount":"3"},
{"locname":"Canada","locCountry":"CA","ProductCount":"36","BreweryCount":"7"},
{"locname":"Chile","locCountry":"CL","ProductCount":"1","BreweryCount":"1"},
{"locname":"China","locCountry":"CN","ProductCount":"97","BreweryCount":"6"},
{"locname":"Dominica","locCountry":"DM","ProductCount":"1","BreweryCount":"1"},
{"locname":"France","locCountry":"FR","ProductCount":"42","BreweryCount":"2"},
{"locname":"Germany","locCountry":"DE","ProductCount":"26","BreweryCount":"3"},
{"locname":"Guatemala","locCountry":"GT","ProductCount":"1","BreweryCount":"1"},
{"locname":"Israel","locCountry":"IL","ProductCount":"1","BreweryCount":"1"},
{"locname":"Italy","locCountry":"IT","ProductCount":"5","BreweryCount":"1"},
{"locname":"Japan","locCountry":"JP","ProductCount":"47","BreweryCount":"1"},
{"locname":"South Korea","locCountry":"KR","ProductCount":"6","BreweryCount":"2"},
{"locname":"Lithuania","locCountry":"LT","ProductCount":"3","BreweryCount":"1"},
{"locname":"Mexico","locCountry":"MX","ProductCount":"24","BreweryCount":"4"},
{"locname":"Netherlands","locCountry":"NL","ProductCount":"21","BreweryCount":"3"},
{"locname":"Romania","locCountry":"RO","ProductCount":"1","BreweryCount":"1"},
{"locname":"Russia","locCountry":"RU","ProductCount":"1","BreweryCount":"1"},
{"locname":"South Africa","locCountry":"ZA","ProductCount":"5","BreweryCount":"2"},
{"locname":"Spain","locCountry":"ES","ProductCount":"79","BreweryCount":"7"},
{"locname":"Turkey","locCountry":"TR","ProductCount":"8","BreweryCount":"1"},
{"locname":"United Arab Emirates","locCountry":"AE","ProductCount":"1","BreweryCount":"1"},
{"locname":"United States","locCountry":"US","ProductCount":"687","BreweryCount":"33"},
{"locname":"Viet Nam","locCountry":"VN","ProductCount":"5","BreweryCount":"2"},
{"locname":"United Kingdom","locCountry":"GB","ProductCount":"8","BreweryCount":"3"}]}
How do I loop thru this to get the different values? I have tried Countries[1].locname, but that gets me can't read property name error. What am I doing wrong?