When I create a form from within a script, I get the following error when trying to do a MyForm.free ? “System Error. Code:5 Access is denied” ?
When I put timers,buttons, panels and labels, I have no problem freeing.
However, when I put a listbox, I get the same error trying to free it?
When I have System.ReportMemoryLeaksOnShutdown := true; I get memory leak errors for the form, listbox and other items from the form?
What am I doing wrong? How can I fix it ?
MyForm := TForm.Create(nil);