4 Sep
2002
4 Sep
'02
6:25 p.m.
Nico de Boer writes:
... if self.methodTestOk('tree_item_active'): # call the dtml-method from python return self.NavItem(self.tree_item_active) ... The problem with my code is that I don't get any error message if one of the methods is deleted. I get a None object back. Is it possible that methodTestOk returns the errormessage? Sure, you use
if methodTestOk(...): return ... else: raise AttributeError, what_is_missing Of course, you would use a different exception, when it fits better. Dieter