forums.silverfrost.com Forum Index forums.silverfrost.com
Welcome to the Silverfrost forums
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Closing window

 
Post new topic   Reply to topic    forums.silverfrost.com Forum Index -> ClearWin+
View previous topic :: View next topic  
Author Message
tbell



Joined: 06 Apr 2006
Posts: 34

PostPosted: Tue Nov 08, 2016 6:08 pm    Post subject: Closing window Reply with quote

I have created a logging window using the %lw and %cc formats. The logging window reports the progress on a long running number crunching process. Everything works fine when the X box in right hand corner of window is pressed and the call-back function associated with the %cc is executed. However, Alt-F4 or "Close" on the main-menu does not close the window as the X box does. What is up? Thanks.
Regards,
Tom Bellissimo
Back to top
View user's profile Send private message
PaulLaidler
Site Admin


Joined: 21 Feb 2005
Posts: 7916
Location: Salford, UK

PostPosted: Wed Nov 09, 2016 9:02 am    Post subject: Reply with quote

Tom

Could you post a simple program that illustrates this issue please.
Back to top
View user's profile Send private message AIM Address
tbell



Joined: 06 Apr 2006
Posts: 34

PostPosted: Wed Nov 09, 2016 6:15 pm    Post subject: Reply with quote

Paul,
Here is the code I use to create the logging window.....

i=WINIO@('%fn[Arial Rounded MT Bold]%ts&',.95D0)
i=WINIO@('%ca[RTSim 32-bit Logging Window]%ns'//
+ '%ww[no_minbox,no_maxbox]%mi[RTCase_icon]'//
+ '%ffStart Time: %ws, '//
1 '%ws%ff%nl%tc[red]Currently Simulating................%tc%ff'
2 //'%nl%ob[thin_panelled]%`rs%ffYear: %`4rd Month: %`2rd'
3 //'%nl%nlCurrent Try: %`rd%nl%nl%20br%cb%lw%cc',
4 start_date,start_time,-1L,CaseLoopCase,
5 CaseLoopYr,CaseLoopMon,NumOptiTries_win,
6 ProcessBar,RGB@(255,255,0),ictrl,LogWinExit)
Tom
Back to top
View user's profile Send private message
tbell



Joined: 06 Apr 2006
Posts: 34

PostPosted: Wed Nov 09, 2016 6:23 pm    Post subject: Reply with quote

Paul,
Depressing the X box in right hand corner of the logging window terminates the window and causes the call-back function LogWinExit to be executed. However, Alt-F4 or "Close" on the main-menu does not close the window.

Tom
Back to top
View user's profile Send private message
PaulLaidler
Site Admin


Joined: 21 Feb 2005
Posts: 7916
Location: Salford, UK

PostPosted: Wed Nov 09, 2016 7:50 pm    Post subject: Reply with quote

Tom

Here is my test program that works correctly for me.
If it works OK for you then you can extend it step by step to what you need.

Code:
program main
integer i,winio@,ictrl
integer,external::LogWinExit
i=winio@('%ww[no_minbox,no_maxbox]&')
i=winio@('%ca[Testing]&')
i=winio@('%ffTesting&')
i=winio@('%lw%cc',ictrl,LogWinExit)
end program main

integer function LogWinExit()
LogWinExit = 0
end function LogWinExit
Back to top
View user's profile Send private message AIM Address
Display posts from previous:   
Post new topic   Reply to topic    forums.silverfrost.com Forum Index -> ClearWin+ All times are GMT + 1 Hour
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group