On 9/13/13 6:06 AM, Ricardo Aráoz wrote: >> If you want to specify the DataStructure, you need to also addField(). I've >> written a >> addFieldsFromDataStructure() method for this. > > Didn't know that method existed. I'll give it a try.
I don't think I ever posted it to Dabo. It goes like this: def addFieldsFromDataStructure(self): max_fill = 0 for field in self.DataStructure: if field[3] is not None: fill = len("%s.%s" % (field[3], field[4])) max_fill = max(max_fill, fill) for field in self.DataStructure: fill = " " * (max_fill - len("%s.%s" % (field[3], field[4]))) if field[3] is not None: self.addField("%s.%s %sas %s" % (field[3], field[4], fill, field[0])) Most of the code has to do with indentation. Paul _______________________________________________ Post Messages to: Dabo-users@leafe.com Subscription Maintenance: http://mail.leafe.com/mailman/listinfo/dabo-users Searchable Archives: http://leafe.com/archives/search/dabo-users This message: http://leafe.com/archives/byMID/523310e5.3080...@ulmcnett.com