Subject Re: closing form
From Ken Mayer <>
Date Mon, 22 Nov 2021 08:43:04 -0800
Newsgroups dbase.getting-started

On 11/22/2021 6:18 AM, Milind Nighojkar wrote:
> Scenerio. form A is opened
> Wanted to close this form
> Iuused a syntax : CLOSE FORMS A
> Get error : No such form A
> Any suggestions

How are you opening form a?

do forma.wfm


set procedure to forma.wfm
fFormA = new formaForm()

? It makes a huge difference.

If you're doing it the first way, that gets tricky, and as Akshat points
out, you should look at findInstance().

However, I almost never use the first way, because the second gives me
the ability to directly control the forms. If I have a situation where
my code is doing a bunch of stuff, and I need to close form A from it,
using the above method, I can do:


And that will do the trick.


*Ken Mayer*
Ken's dBASE Page:
The dUFLP:
dBASE Books:
dBASE Tutorial:
dBASE Web Tutorial: