I've got some code to clean up a few things when exiting my program. I inserted the sub routine's name into the Form's Unload event. It worked initially in the testing stages but doesn't seem to be working when the actual program has been running for a while. I normally close the program out using the close (X) button in the upper right. I'm wondering if there's a better place to stick the exit code, or if it's just a matter of narrowing down what's causing it not to run. Thanks.