A script file is just a list of commands like you would type on the command line in AutoCAD. A script can't interact with a dialog box, so you need to use the command line version of each command. Just go through the operation manually using the command line, then open Notepad and type each command line entry on its own line (no spaces). Save it with a .scr extension. To test it type SCRIPT in AutoCAD and select the file.