Call methods to closed window

kim at kim at
Wed Mar 22 09:29:59 UTC 2023

In OS10.2 I have a problem when I try to call back a method (item reference)
in a window that has closed it causes code to stop and in run time closes
all windows with error 


Do iCallBack.$setAttachments() Returns #F

Close window instance [$cwind().$name]


Where iCallBack is item reference to window instance.  


Normally window is open so no problem.  If window is closed accidently the
active window cannot call method the method before it closes.


I can avoid this by testing if window instance is still open before calling
the method.


Can you calculate a character from an item reference so you can then
calculate the iwindow name.


iCallBack = Reference to $root.$iwindows.wExam_633


If I can calculate a character as wExam_633 I could test to see if Window is
open before calling method to prevent the error


OR is there another better way



Kim Martel



This email has been checked for viruses by AVG antivirus software.

More information about the omnisdev-en mailing list