flat assembler
Message board for the users of flat assembler.

Index > Windows > get remote pc time without using NetRemoteTOD

Author
Thread Post new topic Reply to topic
sleepsleep



Joined: 05 Oct 2006
Posts: 8902
Location: ˛                             ⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣Posts: 334455
sleepsleep
hi there,
is there any alternative (possibly more easy way) to get remote pc date / time? ~ without using NetRemoteTOD ?
Post 25 Mar 2007, 23:55
View user's profile Send private message Reply with quote
sleepsleep



Joined: 05 Oct 2006
Posts: 8902
Location: ˛                             ⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣Posts: 334455
sleepsleep
ok, the below code outputs everything correct, except hour, i wonder why????

the time is 9:54PM here, but if i run the code, i got [816] 2007_03_31_1354
i don't know why... ?

my TIME_OF_DAY_INFO struct is like below, follow the psdk.
Code:
struct TIME_OF_DAY_INFO
        tod_elapsedt            dd ?
        tod_msecs               dd ?
        tod_hours               dd ?
        tod_mins                dd ?
        tod_secs                dd ?
        tod_hunds               dd ?
        tod_timezone            dd ?
        tod_tinterval           dd ?
        tod_day                 dd ?
        tod_month               dd ?
        tod_year                dd ?
        tod_weekday             dd ?
ends
    


Description: tabbed at 8.
Download
Filename: test.txt
Filesize: 1.16 KB
Downloaded: 45 Time(s)

Post 31 Mar 2007, 14:00
View user's profile Send private message Reply with quote
sleepsleep



Joined: 05 Oct 2006
Posts: 8902
Location: ˛                             ⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣⁣Posts: 334455
sleepsleep
just figured out, the return time is GMT 0
i am in +8 zone, so i need to add 8 hours.
.... but why the psdk doesn't highlight this... arghhh

just found out, to change it into local time, we could use
SystemTimeToTzSpecificLocalTime api.
Post 31 Mar 2007, 14:51
View user's profile Send private message Reply with quote
Display posts from previous:
Post new topic Reply to topic

Jump to:  


< Last Thread | Next Thread >
Forum Rules:
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
You cannot attach files in this forum
You can download files in this forum


Copyright © 1999-2020, Tomasz Grysztar.

Powered by rwasa.