clean up mainform