I suspect that I don't understand the naming conventions in bizObj! Below is my
code :-
def createBizobjs(self):
class MembershiptypesBizobj(dabo.biz.dBizobj):
def afterInit(self):
self.DataSource = "MembershipTypes"
self.KeyField = "MTypeID"
self.addFrom("MembershipTypes")
self.addField("MTypeDues")
self.addField("MTypeDesc")
self.addField("MTypeID")
def validateRecord(self):
"""Returning anything other than an empty string from
this method will prevent the data from being saved.
"""
ret = ""
if len(self.MTypeDesc) < 1:
ret = "Must enter a description"
# Add your business rules here.
return ret
membershipTypesBizobj = MembershiptypesBizobj(self.Connection)
self.addBizobj(membershipTypesBizobj)
self.requery()
I'm missing something obvious here I think - as I just get the message :-
AttributeError: /MembershiptypeBizobj' object has no attribute 'MTypeDesc'
Can anyone please put me straight? Thanks
Rodgy
--- StripMime Report -- processed MIME parts ---
multipart/alternative
text/plain (text body -- kept)
text/html
---
_______________________________________________
Post Messages to: [email protected]
Subscription Maintenance: http://leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: http://leafe.com/archives/byMID/[EMAIL PROTECTED]