I have the following
pattern='^([0-9]{0,%s})(\.[0-9]{0,%s})?$' % (self.IntegerWidth, 
self.DecimalWidth)
)
        if re.match(pattern, self.GetValue())==None:
            self.BackColor == "pink"
        else:
            self.BackColor == "white"

self.IntegerWidth = 2
self.DecimalWidth=2

the problem is the pattern allows ".999".  What am I doing wrong?
-- 
John Fabiani
_______________________________________________
Tutor maillist  -  [email protected]
http://mail.python.org/mailman/listinfo/tutor

Reply via email to