DonationCoder.com Software > Post New Requests Here
simple timer
dbarton:
That sounds good. Thanks.
dbarton:
deleted
belkira:
I was not able to get it to work either.
In looking at the AHK Help file it states that the X,Y can be expressions, but it doesn't say that they can be variables. Maybe for the X,Y on tooltip it doesn't recognize variables.....
dbarton:
Sorry I deleted my message because I found the answer.
It does accept variables, but the variable wasn't making it into the function.
It seems you need to declare that variable in the function as global.
So in my case it was just adding:
countdown(p_count="") {
global uY <----------------------- this line
countdown_time:=p_count
countdown_date=16010101
countdown_date+=%countdown_time%, s
Loop {
If (countdown_date >= 16010101010000){
FormatTime, mmss, %countdown_date%, hh:mm:ss
}else{
FormatTime, mmss, %countdown_date%, mm:ss
}
;msgbox %countdown_date%`n%hhmmss%
;//SB_SetText(mmss, 2)
Tooltip, %mmss%, 2, uY
Menu,Tray,Tip,dTIMEmini remaining: %mmss%
; Tooltip, %uY%, 1, 1, 2
;MsgBox The value in the variable named uY is %uY%.
Sleep, 1000
countdown_date+=-1, s
;//IfLess, countdown_date, 16010101, break
if (A_Index>countdown_time) {
Tooltip, DONE, 2,uY
break
cranioscopical:
Can you not achieve what you want by deploying the existing timer plug-in for Find And Run Robot (FARR)?
Timer plugin for FARR
Navigation
[0] Message Index
[#] Next page
[*] Previous page
Go to full version