Speziell mit DB-Libraries wie ADO, DAO u.ä oder auch der Scriptingruntime gibt’s eins über die Löffel, wenn man keinen Destruktor einbaut - also ein „Object = Nothing“ vergisst. So ein Fehler macht dann das Programm zu einem Zombie. Also immer alle und wirklich alle Objecte zerstören, bevor man das Programm endgültig mit Unload Me ins Grab schickt. Kleiner Tip am Rande: Im Event Form_QueryUnload eignen sich solche Prüfroutinen am besten!
VG/SF
[Bei dieser Antwort wurde das Vollzitat nachträglich automatisiert entfernt]
ein „end“ räumt nicht sauber auf. Also vorher auf jeden Fall aufräumen! Selbst MS warnt davor:
„The End statement provides a way to force your program to halt. For normal termination of a Visual Basic program, you should unload all forms. Your program closes as soon as there are no other programs holding references to objects created from your public class modules and no code executing.“ http://msdn.microsoft.com/library/default.asp?url=/l…
Ich hab mir „end“ abgewöhnt!
Viele Grüße
Andreas
[Bei dieser Antwort wurde das Vollzitat nachträglich automatisiert entfernt]