A program that can write a program!

This program writes system parameter files which can then be loaded. Also, it writes a loadable rapid program module. I wasn't sure when I set out to do this if it would even work. It does! I had to cut out some stuff to make it fit this article. But the gist of it is there. Can you tell I like programming ABB robots? Real programming, stuff that maybe no one has ever tried to do before or thought of before. New and interesting challenges keep things from getting boring. The purpose of doing this is explained in the comments below in the program.