Re: [Tutor] Building input for a function call

2010-11-12 Thread David Hutto
Fixed with: def obOpMenu(self): self.oblist = self.canvas.find_withtag('object') self.list = [] for item in self.oblist: self.itemname = self.canvas.gettags(item) if self.itemname[1] != 'default

Re: [Tutor] Building input for a function call

2010-11-12 Thread David Hutto
> > Singled out the two lines for clarity: >> 12:           self.objectsvars = >> 'menuitemhere','menuitemhere','menuitemhere','menuitemhere' >> 17:           self.optionmenu = >> OptionMenu(self.frame,self.var,self.objectsvars) > > > Because in the first case, you're passing 3 items to OptionMen

Re: [Tutor] Building input for a function call

2010-11-12 Thread Evert Rol
> This is a more precise question, the above was after trying different methods, > and it got a little confusing. > > Why in the below does using in line 12:self.objectsvars = > 'menuitemhere','menuitemhere','menuitemhere','menuitemhere', not work, > but placing 'menuitemhere','menuitemhere','menu

Re: [Tutor] Building input for a function call

2010-11-12 Thread David Hutto
This is a more precise question, the above was after trying different methods, and it got a little confusing. Why in the below does using in line 12:self.objectsvars = 'menuitemhere','menuitemhere','menuitemhere','menuitemhere', not work, but placing 'menuitemhere','menuitemhere','menuitemhere','m

Re: [Tutor] Building input for a function call

2010-11-12 Thread David Hutto
Apologies, forgot to add I'm using 2.6.4 on ubuntu 9.10 ___ Tutor maillist - Tutor@python.org To unsubscribe or change subscription options: http://mail.python.org/mailman/listinfo/tutor

[Tutor] Building input for a function call

2010-11-12 Thread David Hutto
Hey Buddy Pals, In the below *function*(if you can call it that yet:) I'm trying to do the following: interpolate this string: 'OptionMenu(self.frame,self.var,'%s','%s')' with this list turned into variables: ['default1', 'default2'] which would become: self.default1 = 'default1' self.defa