
Closing the App - Can it be done?
James,
Typically when an app doesn't close without the "End" statement is means
there are persistant object references that remain after your code is
finished. The easiest method is to set any objects such as forms or
recordsets = Nothing when you are done using the object variable. In
general any variable you use a Set or New keyword with will need to be set
to nothing in order to release. Object cleanup and termination is typically
one of the first things I put together before my objects actually do
anything since it can be troublesome to find an open object reference that
causes an object not to terminate properly. Hope this helps.
Oscar Bowyer
Quote:
> I am using VB 4.0 Pro and NT3.51
> After using the Data Form Designer I realize my app will not "close"
> when you select "close" on the form. In any event the code that is
> automatically placed there is: Unload Me. This seems logical but does
> not allow this to happen and consequently keeps running. The only way
> to "Exit" is to put End for the code. The only problem with this is
> that it kicks me out of the application entirely when I just want to
> close the database form! Any thoughts, comments, answers or questions
> would greatly be appreciated.
> James E. Strouse
> Statistician