Macro for dxf from part w many configs

I'm looking for a way to batch make a bunch of dxfs (many hundreds) of flat surfaces for some fabric cutting. 

My latest brainstorm is a macro to go through the cycle below.. except I'm not savvy w/ the process. 

Thoughts? Please and thank you! 

From a part file:

  1. Go to top view
  2. Rebuild
  3. Save as .dxf by the configuration name into a specific folder
  4. Select next config
  5. Repeat 1-4 until done. 
  6. ​​​​​​​
  7. ​​​​​​​