Z
Zunbeltz Izaola
Hi to all !
I've subclassed ConfigParse in the folowing way.
class DifracConfigParser(ConfigParser):
def __init__(self, defaults=None):
ConfigParser.__init__(self, defaults)
self.readfp(open('defaultdifrac.cfg'))
def save(self):
print "Enter save"
self.write(open('defaultdifrac.cfg','w'))
self.read(open('defaultdifrac.cfg'))
print "OUt save"
I use the values from the defaultdifrac.cfg file in my dialogs (using
wxpython) and change them via validators. After closing a dialog that
changes the values (after validating) i call de save method, but the
file is not changed.
Any Idea?
Thanks in advance
Zunbeltz
--
Zunbeltz Izaola Azkona | wmbizazz at lg dot ehu
dotes
Materia Kondentsatuaren Fisika Saila |
Zientzia eta Teknologia Fakultatea | Phone: 34946015326
Euskal Herriko Unibertsitatea |
PK 644 | Fax: 34 944648500
48080 Bilbo (SPAIN) |
I've subclassed ConfigParse in the folowing way.
class DifracConfigParser(ConfigParser):
def __init__(self, defaults=None):
ConfigParser.__init__(self, defaults)
self.readfp(open('defaultdifrac.cfg'))
def save(self):
print "Enter save"
self.write(open('defaultdifrac.cfg','w'))
self.read(open('defaultdifrac.cfg'))
print "OUt save"
I use the values from the defaultdifrac.cfg file in my dialogs (using
wxpython) and change them via validators. After closing a dialog that
changes the values (after validating) i call de save method, but the
file is not changed.
Any Idea?
Thanks in advance
Zunbeltz
--
Zunbeltz Izaola Azkona | wmbizazz at lg dot ehu
dotes
Materia Kondentsatuaren Fisika Saila |
Zientzia eta Teknologia Fakultatea | Phone: 34946015326
Euskal Herriko Unibertsitatea |
PK 644 | Fax: 34 944648500
48080 Bilbo (SPAIN) |