[Tutor] Addind items to dictionaries

Max Noel maxnoel_fr at yahoo.fr
Mon Oct 4 15:11:33 CEST 2004

On Oct 4, 2004, at 14:02, Bernard Lebel wrote:

> Hello,
> Sorry for the basic question, but I can't seem to be able to retrieve 
> it in the documentation... how
> do you add an item (key + value) to an existing dictionary?
> oModelPathDictionary = {}
> oModelPathDictionary.append( 'myKey': 'myKeyValue' )
> I always get errors when doing this.

	Just use oModelPathDictionary['myKey'] = 'myKeyValue'

-- Wild_Cat
maxnoel_fr at yahoo dot fr -- ICQ #85274019
"Look at you hacker... A pathetic creature of meat and bone, panting 
and sweating as you run through my corridors... How can you challenge a 
perfect, immortal machine?"

More information about the Tutor mailing list