I have a script that gets a partial string that needs to be matched against anãobject/array.ããvar names = {ãAD:"Andorra",ãAE:"United Arab Emirates",ãAF:"Afghanistan",ãAG:"Antigua and Barbuda",ãAI:"Anguilla", ... };ããwrite(' \1cEnter Country Name to Lookup \1w'); ã var lookup = console.getstr();ã writeln('\r\n \1cLooking up \1w'+ lookup);ã for(var i = 0; i <= names.length; i++) {ã if(names[i][1].toUpperCase() ===ãindexOf(lookup).toUpperCase()) {ã writeln(' Found ' + names[i] + ' ' +ãnames[i][0] + ' ' + names[i][1]);ã }ã }ããif I enter, say lookup = 'Andor' it doesn't find anything ... ããany help would be appreciated :)ãããMy doctor said I have the body of a 25 year old
... and the mind of a 10 :-/ãã---ã þ Synchronet þ Realm of Dispair BBS -
http://ephram.synchro.net:82ã