Count Bends - Macro

Is there a way that i can capture the number of bends in asheetmetal part and save them to a configuration specific property?

Thanks for any assistance you can provide.SolidworksApi macros