On Thu, 11 Dec 2008 21:56:19 +, Alan Gauld wrote:
> "Bryan Fodness" wrote
>
>>I am trying to change values in a file. The following code does not
>>seem to
>> find the attribute.
>>
>> def anonymize(obj, attr):
>>try:
>>obj.attr = 'Anonymize'
>>except AttributeError:
>>
"Bryan Fodness" wrote
I am trying to change values in a file. The following code does not
seem to
find the attribute.
def anonymize(obj, attr):
try:
obj.attr = 'Anonymize'
except AttributeError:
pass
This code is looking for an attribute of obj called attr
It is not us
I am trying to change values in a file. The following code does not seem to
find the attribute.
def anonymize(obj, attr):
try:
obj.attr = 'Anonymize'
except AttributeError:
pass
for fname in os.listdir(os.curdir):
plan=ReadFile(fname)
anonymize(plan, 'Name')
It s