Fixed some coding blunders; added file generation items.