Hello List, first question: Is the settings-object an array or a collection?? Onlinehelp says: " ...acts like an read, write array" ....but the syntax for accessing its elements looks like collection.
Main-problem: I'm writing a servicemenu which items should be configured through a settingsfile. I have my seetings-array up and can access each element of it, when I know it's key. My users only have a keypad with numbers from 0 to 9, so my settingsfile looks like this. [Actions] 900 = "WriteToGambasML" 901 = "HaveACupOfCoffee" and so on. The users choice is stored in a variable called: sItem What I need to do is, check if the entered number is a valid choice in my servicemenue, but I don't know how. A simple test for printing each element one by one of the collection??? doesn't work: For Each sElement In hCFG["Actions"] Print sElement; Next Accessing a single element this way doesn't work, too: Print hCFG["Action/sItem"] ...because the quotes masks sItem This try gives me a syntax-error Print hCFG["Action/"sItem] Any ideas?? Sorry, if this a stupid question, but I'm still learning all this OO-stuff. TIA Stevie ------------------------------------------------------------------------- This SF.Net email is sponsored by the Moblin Your Move Developer's challenge Build the coolest Linux based applications with Moblin SDK & win great prizes Grand prize is a trip for two to an Open Source event anywhere in the world http://moblin-contest.org/redirect.php?banner_id=100&url=/ _______________________________________________ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user