Wait window is visible not enough
Moderator: Rathinagiri
Wait window is visible not enough
There is no possibility to determine look of WAIT WINDOW. But often, this window is visible not enough.
It would be great to have control about background color, font color, maybe font size.
regards, Marek
It would be great to have control about background color, font color, maybe font size.
regards, Marek
- Rathinagiri
- Posts: 5471
- Joined: Tue Jul 29, 2008 6:30 pm
- DBs Used: MariaDB, SQLite, SQLCipher and MySQL
- Location: Sivakasi, India
- Contact:
Re: Wait window is visible not enough
I was about to ask. I think Roberto is busy on other preferential work.
East or West HMG is the Best.
South or North HMG is worth.
...the possibilities are endless.
South or North HMG is worth.
...the possibilities are endless.
- Roberto Lopez
- HMG Founder
- Posts: 4004
- Joined: Wed Jul 30, 2008 6:43 pm
Re: Wait window is visible not enough
I'll think about that...mol wrote:There is no possibility to determine look of WAIT WINDOW. But often, this window is visible not enough.
It would be great to have control about background color, font color, maybe font size.
regards, Marek
I'm busy working in other of your wishes right now
Regards/Saludos,
Roberto
(Veritas Filia Temporis)
Roberto
(Veritas Filia Temporis)
Re: Wait window is visible not enough
My Wait Window
I am wondering why nobody had the idea yet to define a window as TOPMOST and activate it by 'Show' and 'Hide'. This works fine for me and you can define the layout, text and colors as you need.
For some "waiting" operations you can also include a progress bar.
Gert
I am wondering why nobody had the idea yet to define a window as TOPMOST and activate it by 'Show' and 'Hide'. This works fine for me and you can define the layout, text and colors as you need.
For some "waiting" operations you can also include a progress bar.
Gert
Code: Select all
#include "hmg.ch"
#define C_LIGHTBLUE {165,175,245}
Function Main
DEFINE WINDOW Win_1 ;
AT 0,0 WIDTH 400 HEIGHT 400 ;
TITLE "Gert's WAIT WINDOW DEMO" ;
MAIN
@ 70,70 BUTTON Button_1 CAPTION 'WAIT WINDOW "Processing..." NOWAIT' ACTION Test1() WIDTH 250
@ 100,70 BUTTON Button_2 CAPTION 'WAIT CLEAR' ACTION Test2() WIDTH 250
END WINDOW
DEFINE WINDOW Win_Wait ;
AT 0,0 WIDTH 225 HEIGHT 80 ;
TOPMOST NOSHOW NOSIZE NOCAPTION NOAUTORELEASE BACKCOLOR C_LIGHTBLUE
@ 20,30 LABEL L1 VALUE 'please wait...' WIDTH 180 HEIGHT 40;
FONT 'ARIAL' SIZE 20 FONTCOLOR BLUE BOLD BACKCOLOR C_LIGHTBLUE
END WINDOW
CENTER WINDOW Win_1
CENTER WINDOW Win_Wait
ACTIVATE WINDOW Win_1
ACTIVATE WINDOW Win_Wait
Return
procedure test1()
Win_Wait.show
return
procedure test2()
Win_Wait.hide
return
- Rathinagiri
- Posts: 5471
- Joined: Tue Jul 29, 2008 6:30 pm
- DBs Used: MariaDB, SQLite, SQLCipher and MySQL
- Location: Sivakasi, India
- Contact:
Re: Wait window is visible not enough
Nice one. It is very much useful. Thanks a lot Gert.
East or West HMG is the Best.
South or North HMG is worth.
...the possibilities are endless.
South or North HMG is worth.
...the possibilities are endless.
- Pablo César
- Posts: 4059
- Joined: Wed Sep 08, 2010 1:18 pm
- Location: Curitiba - Brasil
Wait window is visible not enough
Hi All !
I prepared an improved version of our colleague Gert:
I hope you enjoy it and be usefull too
I prepared an improved version of our colleague Gert:
Code: Select all
#include <hmg.ch>
#define C_LIGHTBLUE {165,175,245}
Function Main()
Set Century On
DEFINE WINDOW Win_1 ;
AT 0,0 WIDTH 600 HEIGHT 450 BACKCOLOR BLUE ;
TITLE "WAIT WINDOW DEMO" MAIN
ON KEY ESCAPE ACTION ThisWindow.Release
@ 030,160 BUTTON Button_1 CAPTION 'WAIT/CLEAR WINDOW "Auto-Release" NOWAIT' ACTION Test1() WIDTH 290
@ 070,160 BUTTON Button_2 CAPTION 'WAIT WINDOW "Start Processing" NOWAIT' ACTION Test2() WIDTH 290
@ 100,160 BUTTON Button_3 CAPTION 'WAIT CLEAR "Stop Processing" ' ACTION Test3() WIDTH 290
DEFINE STATUSBAR FONT "Courier New" SIZE 9
DATE WIDTH 85
STATUSITEM HMG_PadC("Press [Esc] to exit",64) ACTION ThisWindow.Release RAISED WIDTH 450
CLOCK WIDTH 65
END STATUSBAR
END WINDOW
DEFINE WINDOW Win_Wait AT 0,0 WIDTH 400 HEIGHT 64 ;
TOPMOST NOSHOW NOCAPTION NOSYSMENU NOAUTORELEASE BACKCOLOR C_LIGHTBLUE
@ 20,10 LABEL L1 VALUE 'Please wait...' WIDTH 380 HEIGHT 20 CENTERALIGN ;
FONT 'ARIAL' SIZE 14 FONTCOLOR BLUE BOLD BACKCOLOR C_LIGHTBLUE
END WINDOW
CENTER WINDOW Win_1
CENTER WINDOW Win_Wait
ACTIVATE WINDOW Win_1, Win_Wait
Return Nil
Function Test1()
Local i
Win_1.Button_2.Enabled := .F.
Win_1.Button_3.Enabled := .F.
Win_Wait.show
For i=1 To 10
Win_Wait.L1.VALUE := 'Please wait '+Alltrim(Str(i))+" second"+If(i=1,"","s")
hb_IdleSleep( 0.5 )
Next
Win_Wait.hide
Win_1.Button_2.Enabled := .T.
Win_1.Button_3.Enabled := .T.
Return Nil
Function Test2()
Win_1.Button_1.Enabled := .F.
Win_Wait.show
Win_Wait.L1.VALUE := 'Please wait...'
Return Nil
Function Test3()
Win_1.Button_1.Enabled := .T.
Win_Wait.hide
Return Nil
Last edited by Pablo César on Wed Dec 14, 2016 12:06 am, edited 1 time in total.
HMGing a better world
"Matter tells space how to curve, space tells matter how to move."
Albert Einstein
"Matter tells space how to curve, space tells matter how to move."
Albert Einstein
- serge_girard
- Posts: 3165
- Joined: Sun Nov 25, 2012 2:44 pm
- DBs Used: 1 MySQL - MariaDB
2 DBF - Location: Belgium
- Contact:
Re: Wait window is visible not enough
Yes, it is!
Thanks, Serge
Thanks, Serge
There's nothing you can do that can't be done...
-
- Posts: 1275
- Joined: Tue Sep 03, 2013 4:22 am
- Location: Tecámac, México
Re: Wait window is visible not enough
Gracias Pablo César por compartir!
Saludos
Saludos
- vagblad
- Posts: 160
- Joined: Tue Jun 18, 2013 12:18 pm
- DBs Used: MySQL,DBF
- Location: Thessaloniki, Greece
Re: Wait window is visible not enough
Thanks Gert and Pablo!
Vagelis Prodromidis
Email: vagblad@gmail.com, Skype: vagblad
Email: vagblad@gmail.com, Skype: vagblad
Re: Wait window is visible not enough
Thank you Gert and Pablo!
Best Regards,
Nikos.
os: Windows Server 2019 - 64
Nikos.
os: Windows Server 2019 - 64