Shankar Giri Venkita Giri wrote:
File "c:\Python27\lib\site-packages\GUI\TextField.py", line 55, in set_text self._win.SetWindowText(x.replace("\n", "\r\n")) AttributeError: 'float' object has no attribute 'replace'This is probably occurring because a float is being passed to the TextField. The Cocoa version works fine but win32 errors out.
You're not supposed to be putting a float into a text field, only a string. If you're getting away with it in Cocoa, that's just an accident. I could put a typecheck into the Cocoa version to prevent that, but I'm not sure it's worth the effort. Such LBYL checks are generally not considered pythonic. -- Greg _______________________________________________ Pygui mailing list [email protected] http://mail.python.org/mailman/listinfo/pygui
