-
I am using App.previnstance to tell whether the user has already got this application open and if so am not letting them open it twice.
Sometimes, however, it seems as though this is telling me it is already open when it isn't, and I have to reboot the machine to reset it. Any ideas?
-
Hit Ctrl-Alt-Del and find out if the app really isn't open. Maybe the app is open, but not visible. Could be a coding error in the closing method. This could be a form that was hidden and not unloaded, or a property of a form was accessed, and loaded that form, or a doevents was used in an unload event.
-
You should Unload the form and not force it to close with End or Ctrl Alt Del as it may still remain as active
-
I believe if you are checking for the PrevInstance in the Load of the main form, you would have to use "End" instead of "Unload Me" or else the program will get stuck in memory. All other cases Unload seems to be a better choice.
Josh