[Zope] Another problem...
Donald Holten
donner@biophysics.lanl.gov
Fri, 20 Aug 1999 14:46:07 -0600 (MDT)
I have the following Initialize method:
def Initialize(self, REQUEST):
self.count = 0
REQUEST=REQUEST.set('count', self.count)
self.propertysheets.Properties.manage_changeProperties(REQUEST)
self.extendedIPlist = ""
REQUEST=REQUEST.set('extendedIPlist', self.extendedIPlist)
self.propertysheets.Properties.manage_changeProperties(REQUEST)
datetmp = os.popen("date", 'r')
self.dateOfInit = datetmp.readlines()[0]
datetmp.close()
splitdate = string.split(self.dateOfInit)
day = splitdate[2]
month = splitdate[1]
year = splitdate[5]
self.dateOfInit = ""
while count < len(datefmt):
element = datefmt[count]
if element == "D":
self.dateOfInit = self.dateOfInit + day
elif element == "M":
self.dateOfInit = self.dateOfInit + month
elif element == "Y":
self.dateOfInit = self.dateOfInit + year
else:
self.dateOfInit = self.dateOfInit + element
count = count + 1
REQUEST=REQUEST.set('dateOfInit', self.dateOfInit)
self.propertysheets.Properties.manage_changeProperties(REQUEST)
return
I call Initialize by:
<!--#var standard_html_header-->
<dtml-with WebSolveAccess>
<dtml-call "Initialize(this(), REQUEST)">
</dtml-with>
<!--#var standard_html_footer-->
Unfortunately I get the following error when using it:
Error Type: AttributeError
Error Value: 'None' object has no attribute 'set'
It sounds to me like REQUEST=None, but I don't know where that's coming
from... Any ideas of what is wrong with this? Thanks!
Donner