Sign in to follow this  
Followers 0
fataly

_tickstotime lol?

2 posts in this topic

My problems is this, when i start this, its only show 1 sec alltime, not move to sec 2 or 3 etc..

how i get time to move?

#include <date.au3>

While 1

Dim $begin, $diff, $hours, $mins, $seconds

$begin = TimerInit()

Sleep(1000)

$diff =Int( TimerDiff($begin))

_TicksToTime($diff,$hours,$mins,$seconds)

$AllTime = "Elapsed Time"& $hours & "hours " & $mins & "mins " & $seconds & "secs"

SplashTextOn("time table", @CRLF _

& "==============================" & @CRLF _

& "Total Time: " & $AllTime & @CRLF _

& "==============================", 200, 300, 1070 , 0 ,2 ,"", 8, "")

WEnd

Share this post


Link to post
Share on other sites



By not resetting the base time each loop :P

#include <date.au3>
Dim $begin, $diff, $hours, $mins, $seconds
$begin = TimerInit()
While 1
    Sleep(1000)
    $diff = Int(TimerDiff($begin))
    _TicksToTime($diff, $hours, $mins, $seconds)
    $AllTime = "Elapsed Time" & $hours & "hours " & $mins & "mins " & $seconds & "secs"
    SplashTextOn("time table", @CRLF _
             & "==============================" & @CRLF _
             & "Total Time: " & $AllTime & @CRLF _
             & "==============================", 200, 300, 1070, 0, 2, "", 8, "")
WEnd

Visit the SciTE4AutoIt3 Download page for the latest versions        Beta files                                                          Forum Rules
 
Live for the present,
Dream of the future,
Learn from the past.
  :)

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