Macro's. What are they and what are the benefits?

i see alot of talk about running macro's. i have used VERY LITTLE in excel so im curious how they work in SW? and how they benefit us?

SolidworksApi macros