Re: dictionary as attribute of a class...

2011-01-05 Thread tinauser
On Jan 5, 4:34 pm, Peter Otten <__pete...@web.de> wrote: > tinauser wrote: > > Hallo list, > > here again I have a problem whose solution might be very obvious, but > > I really cannot see it: > > I have a class having as attribute a dictionary whose keys are nam

dictionary as attribute of a class...

2011-01-05 Thread tinauser
Hallo list, here again I have a problem whose solution might be very obvious, but I really cannot see it: I have a class having as attribute a dictionary whose keys are names and values are instance of another class. This second class has in turn as an attribute a dictionary. I want a function of t

Re: sqlite autoincrement of primary key

2010-11-29 Thread tinauser
On Nov 29, 10:49 pm, "D'Arcy J.M. Cain" wrote: > On Mon, 29 Nov 2010 19:11:18 + (UTC) > > Tim Harig wrote: > > >   INSERT INTO foo (name) VALUES ('xxx') > > > > That's the standard SQL way. > > > Yes, it works; but, the OP asked specifically to be able to enter all of > > the field values, in

Re: sqlite autoincrement of primary key

2010-11-29 Thread tinauser
On Nov 29, 7:28 pm, Tim Harig wrote: > On 2010-11-29, tinauser wrote: > > > ''' > > INSERT INTO 'foo' VALUES (?,?) > > ''' > > ,('NULL','yyy')) > > s/'NULL'/None/ > > > I get a dat

sqlite autoincrement of primary key

2010-11-29 Thread tinauser
Dear List I'm writing an application that has to create and populate an SQLite database. I'm doing pretty well, but now I'm facing a problem I can not solve. I create a table with a primary key autoincrement, something like sqlcmd="CREATE TABLE foo (id INTEGER PRIMARY KEY AUTOINCREMENT, name TEXT

Re: emdding python gui in c code - OS independent

2010-10-11 Thread tinauser
On Oct 11, 6:49 pm, Chris Rebert wrote: > On Mon, Oct 11, 2010 at 6:16 AM, tinauser wrote: > > hi there, > > i need to embed python GUI in a c++ code. I've seen that,while on > > windows running GUI is no problem, in mac i need to use pythonw > > instead python.

emdding python gui in c code - OS independent

2010-10-11 Thread tinauser
hi there, i need to embed python GUI in a c++ code. I've seen that,while on windows running GUI is no problem, in mac i need to use pythonw instead python. the question is,how should i tell the program that if the OS is mac, it should pythonw, otherwise python is fine? -- http://mail.python.org/ma

Re: open file on mac

2010-10-10 Thread tinauser
On Oct 10, 11:44 pm, Benjamin Kaplan wrote: > On Sun, Oct 10, 2010 at 5:29 PM, tinauser wrote: > > On Oct 10, 6:54 am, Lawrence D'Oliveiro > central.gen.new_zealand> wrote: > >> In message > >> , > > >> tinauser wrote: > >> > now,

Re: open file on mac

2010-10-10 Thread tinauser
On Oct 10, 6:54 am, Lawrence D'Oliveiro wrote: > In message > , > > tinauser wrote: > > now,the file will be opened only if i give the full path, not if i > > give only the name of the file, although the folder is in the path. > > what am I missing? > > Th

open file on mac

2010-10-08 Thread tinauser
hallo, i'm sorry if the question is very stupid, but i cannot understand what i'm doing wrong here. i have this myModule.py class Starter: def init(self,num): print "hithere!" print "the answer is ",num import sys,os print "path:",sys.path print "bye"

open file on mac

2010-10-08 Thread tinauser
hi, sorry if it is a stupid qustio,but i cannot figure out where's the problem. i've a simpleModule: class Starter: def init(self,num): print "hithere!" print "the answer is ",num import sys,os print "path:",sys.path try: #f = open("/Users/l