On Wednesday 09 January 2008 11:06:55 pm Simen Haugen wrote: > class MatchBiz(dbiz.dBizobj): > def beforeInit(self): > self.Caption = "Matches" > self.Encoding = "latin-1" > self.DataSource = "tbl_matches" > self.KeyField = "project,bnummer,telefonval" > self.AutoPopulatePK = False > > I bind this datasource to a grid. Calling bizobj.new() creates a new > record. Editing in a grid reflects the values in the dataset. When > calling save() I get no messages at all. Calling saveAll() gives me an > exception, "Invalid row specified". > Even if I answer No or Cancel when asking to save to data I get this > error. > > isChanged() shows False, isAnyChanged() shows True. > >
Please try testing without the composite primary key. If that works then we can determine the best way to support your composite primary key. Like maybe using beforeSave() to set the proper values. It might even be possible to setup a routine in the bizObj.validateField to support your composite key. I have been able to play some tricks in validateField to support foreign keys (FK) in my primary bizObject. -- John Fabiani _______________________________________________ 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/dabo-users/[EMAIL PROTECTED]
