how to access immediate unknown key in object. in pic \"367:sl\" is dynamic key and i want to access cptyName value which is in \"367:sl\". Thanks in advance
You can iterate through the object.
var quotes = {
'367:sl': 'cptyname'
}
for(var i in quotes) {
alert(quotes[i]);
}
Demo
If your dynamic key is the only key in quotes
object, you can get the first key and then access value with:
var firstKey = Object.keys(quotes)[0];
var cptyName = quotes[firstKey].cptyName;
http://jsfiddle.net/mGZpa/