Converting Unicode to integer
Nikola.Plejic at pu.CARNet.hr
Tue Aug 27 12:51:49 CEST 2002
It doesn't work for me - still the same here. I have an unicode string as a
variable that was inputted via a TextField (anyGUI).
"Max M" <maxm at mxm.dk> wrote in message news:3D6B469B.6070403 at mxm.dk...
> Nikola Plejic wrote:
> > Is it possible to convert an Unicode string to an integer? I'm working
> > on a program in AnyGUI and it seems to make everything in TextLabels
> > an Unicode string, and if I try to add i.e. 2 numbers (let's say 2 and
> > 3) I get 23 instead of 5.
> > I tried using int() but that doesn't seem to work.
> It works for me:
> >>> int(u'21') + 21
> regards Max M
More information about the Python-list