>>>I need to be able to close an open form from code. I don't want to close the entire application, just a form. I can identify the form and get the handle with an API call. Now what? TIA
>>
>>If you can get a reference to this form, can you just call myForm.Release() ?
>
>The code to close the form needs to be outside the form itself. In this case, the code would reside in a menu command.
I understand, but you still will call the release() method once you have a reference to the form.
E.g.
for each loForm in _screen.Forms
if loForm.Name = "FormWeWantToClose"
loForm.Release()
exit
endif
next
If it's not broken, fix it until it is.
My Blog