include \masm32\include\masm32rt.inc
.data?
buffer db 80 dup(?)
timeinfo SYSTEMTIME <>
.code
format$ db "Now it's %I:%M %p", 0
start:
invoke crt_strftime, addr buffer, 80, addr format$, addr timeinfo
print str$(eax), " bytes returned", 13, 10
print LastError$(), 13, 10
inkey offset buffer
exit
end start
Works like a charm, except that the output is wrong. Same format$ in C works just fine...
Where is my error?
17 bytes returned
Operazione completata.
Now it's 12:00 AM
CANCELLED
8)
Just found Erol's solution (http://masm32.com/board/index.php?topic=2506.0). It is simple a lil'bit more complicated :(