Sign in to follow this  
Followers 0
toofat

HELP - SetData Time

5 posts in this topic

This doesn't work for me.

$Time = GUICtrlCreateDate ('23:59:59', 100, 112, 75, 20, $DTS_TIMEFORMAT)
GUICtrlSetData ($Time, '22:13:24')

It just keeps displaing '23:59:59'.

What am I doing wrong ???

P.S.

Sorry for bad spelling, if any.

Share this post


Link to post
Share on other sites



This doesn't work for me.

$Time = GUICtrlCreateDate ('23:59:59', 100, 112, 75, 20, $DTS_TIMEFORMAT)
GUICtrlSetData ($Time, '22:13:24')

It just keeps displaing '23:59:59'.

What am I doing wrong ???

P.S.

Sorry for bad spelling, if any.

Set a variable at the beginning of your script, then initialize your date object :

You'll need to format your $currentDate variable, but it works ;)

$currentDate = @MON &"/" & @MDAY&"/" & @Year
$DateBoxControl = GUICtrlCreateDate($currentDate, 13, 64, 106, 24, $WS_TABSTOP)

Share this post


Link to post
Share on other sites

Set a variable at the beginning of your script, then initialize your date object :

You'll need to format your $currentDate variable, but it works ;)

$currentDate = @MON &"/" & @MDAY&"/" & @Year
$DateBoxControl = GUICtrlCreateDate($currentDate, 13, 64, 106, 24, $WS_TABSTOP)
I think you didn't understand what I was asking ... Through GUICtrlCreateDate and $DTS_TIMEFORMAT I am setting time control (not date). When I try to change the set time to another time with GUICtrlSetData, well, the time stays the same.

Share this post


Link to post
Share on other sites

I did misunderstand.

I suggest that you set the $currentDate (like in my script, but formatted for time) to be your dynamic updating variable and try that, I'll give it a go here in a few minutes.

Share this post


Link to post
Share on other sites

OK, my fault. Got it. Not like this ...

$Time = GUICtrlCreateDate ('23:59:59', 100, 112, 75, 20, $DTS_TIMEFORMAT)
GUICtrlSetData ($Time, '22:13:24')
oÝ÷ Øl¥u·¥G­+ºÚ"µÍÌÍÕ[YHHÕRPÝÜX]Q]H
    ÌÎNÌÎNNNIÌÎNËLLL
ÍK ÌÍÑ×ÕSQQÔPU
BÕRPÝÙ]]H
    ÌÍÕ[YK   ÌÎNÌ
ÌLKÌÌLÎ ÌÎNÊB

where the date portion of the time can be any date (current date maybe) because GUICtrlRead will return just the time and time control will display just the specified time ...

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0