Convert to max geometry by MaxScript?

would it be possible to perform “Convert to max geometry” operation by maxscript?

i need simple 3-steps script:

  • convert all CScatters objects to max geometry
  • delete all CScatters and distribution objects
  • save scene (3dsmax 2017) and close 3dsmax

thank you in advance