I use the following code to create a window to accept text written to the standard output from Fortran. I do this so that I can control the size and caption for the Window (rather than using the default output window of Clearwin). My question is : is it possible to obtain a handle for this window, such that another process can detect if this window is still open. Similar to the way that setting a class using %nc allows other procesess to detect whether that window is still open (using FindWindowA), in other words can a second instance of a program detect that a previous instance is still running?
integer function CreateWindow(caption,x0,y0,x1,y1)
C ---- creates a window for I/O with caption 'caption' C_EXTERNAL CREATE_WINDOW '__create_window' (INSTRING,VAL,VAL, & &VAL,VAL):INTEGER4 character(*) caption integer x0,y0,x1,y1
CreateWindow = create_window(caption,x0,y0,x1,y1)
end function CreateWindow