A
Ajay Brar
hi!
i have the following code that doesn't work
contextForm = {"contextName":"test2","contextDescription":"test22","number":"1","contextName1":"test1","contextDescription1":"test11"}
if contextForm.has_key("number"):
num=contextForm["number"].value
the error i get is
AttributeError: 'str' object has no attribute 'value'
the trace is
bash$ python
Python 2.3.4 (#3, May 28 2004, 13:31:19)
[GCC 2.95.2 19991024 (release)] on sunos5
Type "help", "copyright", "credits" or "license" for more information..... num=contextForm["number"].value
....
Traceback (most recent call last):
File "<stdin>", line 2, in ?
AttributeError: 'str' object has no attribute 'value'
any ideas why it isn't working?
thanks
Ajay Brar
CS Honours 2004
Smart Internet Technology Research Group
http://www.it.usyd.edu.au/~abrar1
i have the following code that doesn't work
contextForm = {"contextName":"test2","contextDescription":"test22","number":"1","contextName1":"test1","contextDescription1":"test11"}
if contextForm.has_key("number"):
num=contextForm["number"].value
the error i get is
AttributeError: 'str' object has no attribute 'value'
the trace is
bash$ python
Python 2.3.4 (#3, May 28 2004, 13:31:19)
[GCC 2.95.2 19991024 (release)] on sunos5
Type "help", "copyright", "credits" or "license" for more information..... num=contextForm["number"].value
....
Traceback (most recent call last):
File "<stdin>", line 2, in ?
AttributeError: 'str' object has no attribute 'value'
any ideas why it isn't working?
thanks
Ajay Brar
CS Honours 2004
Smart Internet Technology Research Group
http://www.it.usyd.edu.au/~abrar1