Hi I am stuck on the following, if no_of _items, dollars_items are not used the total_sale_price is left blank I get the follow message
compute=lambda r: r['no_of_items']*r['dollars_items']), TypeError: unsupported operand type(s) for *: 'NoneType' and 'NoneType' If I leave the no_by weight, cent_per_kg i get the following compute=lambda r: r['estimated_weight']*r['no_by_weight']*r['cents_per_kg']), TypeError: unsupported operand type(s) for *: 'NoneType' and 'NoneType' Field('no_of_items', 'integer'), Field('dollars_items', 'double'), Field('sub_total_items','double', compute=lambda r: r['no_of_head']*r['dollars_hd']), Field('no_by_weight', 'integer'), Field('estimated_weight', 'double'), Field('cents_per_kg', 'double'), Field('sub_total_kg', 'double', compute=lambda r: r['estimated_weight']*r['no_by_weight']*r['cents_per_kg']), Field('total_sale_price', 'double', compute=lambda r: r['sub_total_hd'] +r['sub_total_kg']), Where am I going wrong cheers -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) - http://github.com/web2py/web2py (Source code) - https://code.google.com/p/web2py/issues/list (Report Issues) --- You received this message because you are subscribed to the Google Groups "web2py-users" group. To unsubscribe from this group and stop receiving emails from it, send an email to web2py+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.