For generating custom file formats you'll have to use a Java action. You may get lucky and find someone here that did it before though. If not, please do submit it to the Appstore if you're going to make a generic module for it :)
It has been done before, the project I maintain was build by Mendix and contains a Java action to generate CLIEOP files. Maybe you should ask around at Mendix.