wxTextCtrl + wxGrid

Steve Holden sholden at holdenweb.com
Tue Jul 30 06:19:41 EDT 2002


"Thorsten Gawantka" <t.gawantka at freenet.de> wrote ...
> Hi Group,
> how can I get the Value of wxTextCtrl into a Cell of wxGrid?
> my actual code is
>
> --
> ## Copy the textCtrl.Value into gridCell
> self.grid.SetCellValue(i, 0, self.edit_p1.GetValue)
> ##
> --
>
> this is not functional, because the python interpreter
> want to have a string.
> How can I get this solved?
>

You probably want to *call* the GetValue method of the wxTextCtrl rather
than referring to it. It's a mistake most have made ... try

    self.grid.SetCellValue(i, 0, self.edit_p1.GetValue())

regards
-----------------------------------------------------------------------
Steve Holden                                 http://www.holdenweb.com/
Python Web Programming                http://pydish.holdenweb.com/pwp/
-----------------------------------------------------------------------








More information about the Python-list mailing list