So you can open a .cmd file
A .bat or a .cmd-file batch processing, but only Text files. Double-click on the file, Windows doesn't open the file, but starts the corresponding Software application that is installed on the PC. To open the file, you will need a simple Text Editor.
- A you want to .cmd-open a file, click with the right mouse button.
- In the context menu, select "Open with" a text editor, such as Notepad ++.
- Should change to the file, however, only if you are sure of what you are doing - otherwise the associated program does not start perhaps.

DOS: autoexec.bat open
A tutorial on how to Batch-files to create, you will find, in a further practical tip.