Re: application.createform problem

From: Kurt Barthelmess (kbarthelmess_at_compuserve.com)
Date: 10/13/03


Date: Mon, 13 Oct 2003 20:39:04 GMT


"scchui" <scchui@i-cable.com> wrote:

> When run, Form1 checks whether the software is legal. If not, it will call
>application.terminate. However, I received an access violation error when I
>call application.termainate. I think AV error came from other Forms ,
>because if I comment them, no AV error occurred.

That's probably not a good idea, as you found. Your best bet would be
to put the security check into a procedure and call that from your
dpr before you allow the application to start creating the forms.

There are probably 100's of other approaches, but the simplest is not
to allow stuff to happen before it starts to happen<g>.

Good luck.

Kurt