Board index » delphi » Form Close - Invalid Parameter error

Form Close - Invalid Parameter error

Hi,
When I close a form, I get an error message 'Invalid Parameter'
The form has lots of components, some getting data from a datamodule.
I disabled all controls from the queries, and made all queries
inactive before closing, but still this dreaded message.
Any idea how to find out what causes it please?
Thank You
Johan Smit
 

Re:Form Close - Invalid Parameter error


How do you close the form? With click "Close" command in system menu (or X
in upper-right corner of window)? Or with a line of code:

--
  close;
--

or

--
  FormClose(self);
--

If you're closing it with "FormClose(???)", be sure to write a form's name
or "self" or "sender" over "???".

Matija

Quote
Johan Smit <smi...@mweb.co.za> wrote in message

news:37e880fa.1216126@news.mweb.co.za...
Quote
> Hi,
> When I close a form, I get an error message 'Invalid Parameter'
> The form has lots of components, some getting data from a datamodule.
> I disabled all controls from the queries, and made all queries
> inactive before closing, but still this dreaded message.
> Any idea how to find out what causes it please?
> Thank You
> Johan Smit

Re:Form Close - Invalid Parameter error


The problem is morelikely caused by a procedure/function call. Make sure you
have correctly call the procedure/function.

Quote
Johan Smit <smi...@mweb.co.za> wrote in message

news:37e880fa.1216126@news.mweb.co.za...
Quote
> Hi,
> When I close a form, I get an error message 'Invalid Parameter'
> The form has lots of components, some getting data from a datamodule.
> I disabled all controls from the queries, and made all queries
> inactive before closing, but still this dreaded message.
> Any idea how to find out what causes it please?
> Thank You
> Johan Smit

Re:Form Close - Invalid Parameter error


On Wed, 22 Sep 1999 20:20:19 +0200, "Matija Polajnar"

Quote
<Matija.Polaj...@guest.arnes.si_NOSPAM_> wrote:
>How do you close the form? With click "Close" command in system menu (or X
>in upper-right corner of window)? Or with a line of code:

>--
>  close;

That is the one. It is needed to update some things before closing.
I commented out all the code in the form , then it went away. Then I
uncommented the code part by part, and it is still gone. Strange!
I am puzzled. I do not know what parameters are required to close a
form, or how to trace into a problem like that.
Thanks to everybody who replied.
Regards
Johan Smit

Other Threads