Memory read error on quit

Posted by ojfoggin on 06-Jul-2011 05:26

Hi All,

At the moment our software has a check so that if a user has remained logged into the software over night and they try to do something it will stop what they are trying to do ad pop up a messge like... "You have been logged in overnight, please restart the software".

I am trying to change this so that it says... "You have been logged in overnight.  The system will now close." and then when they press OK it will close the program.

This is because there were various loopholes that people could get through to carry on working.

However, I have tried to quite the program using different methods...

APPLY "close" TO THIS-PROCEDURE.

and...

QUIT.

but when I do that I always get a windows error.

prowin32.exe - Application Error.

The instruction at <memory ref> referenced memory at <memory ref>.  The memory could not be "read".

I'm not sure what I can do now to check why this is happening?

Could anyone provide any pointers please?

Thanks

Oliver

All Replies

Posted by ojfoggin on 07-Jul-2011 07:28

Well, I worked out that if enabled the "Are you sure you want to quit?" window the memory error didn't happen.

The only thing I can think is that the trigger needed to finish and the "wait" on the other window allowed the trigger to finish properly before the quit ran.

I even tried letting the "Are you sure" window running and shutting it down automatically but that didn't work either.

It needed to stay there and have the user press the "OK" button and it worked fine.

Not really sure what's going on there so I gave up and left it how it was.

This thread is closed