|
forums.silverfrost.com Welcome to the Silverfrost forums
|
View previous topic :: View next topic |
Author |
Message |
jjgermis
Joined: 21 Jun 2006 Posts: 404 Location: Nürnberg, Germany
|
Posted: Fri Feb 01, 2008 1:40 pm Post subject: Closig a window using ClearWin |
|
|
Hi,
I am using a bar to display the progress of a simulation program. Normally I close this using the default X at the top right of the window containing the bar.
In future the bar window should close automatically after the simultion is done. The problem is that I do not know how to to this. Running the small example program below explains the problem.
How can I close the bar from inside the program?
Jacques
Code: |
winapp
include <windows.ins>
integer ctrl
double precision d
d = 0.0d0
i = winio@('%ca[Bar format]&')
i = winio@('Processing ....%2nl&')
i = winio@('%20br&',d,RGB@(255,0,0))
i = winio@('%lw',ctrl)
do while(d < 1.0d0)
do i=1,100000
enddo
d=d+0.01d0
call window_update@(d)
enddo
end
|
|
|
Back to top |
|
|
PaulLaidler Site Admin
Joined: 21 Feb 2005 Posts: 7924 Location: Salford, UK
|
Posted: Fri Feb 01, 2008 4:30 pm Post subject: |
|
|
Code: | winapp
include <windows.ins>
integer ctrl
double precision d
d = 0.0d0
i = winio@('%ca[Bar format]&')
i = winio@('Processing ....%2nl&')
i = winio@('%20br&',d,RGB@(255,0,0))
i = winio@('%lw',ctrl)
do while(d < 1.0d0)
do i=1,100000
enddo
d=d+0.01d0
call window_update@(d)
enddo
ctrl = 0
call window_update@(ctrl)
end |
|
|
Back to top |
|
|
jjgermis
Joined: 21 Jun 2006 Posts: 404 Location: Nürnberg, Germany
|
Posted: Mon Feb 04, 2008 4:03 pm Post subject: Minimise |
|
|
Hi Paul,
thanks! It works now as I expected it to work.
Another minor thing that I cannot figure out or at least does not work is to open the window with a minimise button. Only a X appear at the top right of the window. During a verly long simulation I would like to minimise the window. How do I get the minise button to be active?
Code: |
winapp
include <windows.ins>
integer ctrl
double precision d
d = 0.0d0
i = winio@('%mi[pre]&')
i = winio@('%ca[Test]&')
i = winio@('Processing ....%2nl&')
i = winio@('%20br&',d,RGB@(255,0,0))
i = winio@('%lw',ctrl)
do while(d < 1.0d0)
do i=1,100000
enddo
d=d+0.01d0
call window_update@(d)
enddo
ctrl = 0
call window_update@(ctrl)
end
resources
pre ICON solve.ico
|
Jacques |
|
Back to top |
|
|
PaulLaidler Site Admin
Joined: 21 Feb 2005 Posts: 7924 Location: Salford, UK
|
Posted: Mon Feb 04, 2008 4:27 pm Post subject: |
|
|
See %ww and its options. |
|
Back to top |
|
|
|
|
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
|