mirror of
https://github.com/janbodnar/Windows-API-examples.git
synced 2024-11-24 11:25:30 +00:00
Create winapi_string_fillbuffer.c
This commit is contained in:
parent
67fbdb2b24
commit
2a0bf7c11b
18
strings/winapi_string_fillbuffer.c
Normal file
18
strings/winapi_string_fillbuffer.c
Normal file
@ -0,0 +1,18 @@
|
||||
#include <windows.h>
|
||||
#include <wchar.h>
|
||||
|
||||
#pragma comment(lib, "User32.lib")
|
||||
|
||||
int wmain(void) {
|
||||
|
||||
SYSTEMTIME st = {0};
|
||||
wchar_t buf[128] = {0};
|
||||
|
||||
GetLocalTime(&st);
|
||||
wsprintfW(buf, L"Today is %lu.%lu.%lu\n", st.wDay,
|
||||
st.wMonth, st.wYear);
|
||||
|
||||
wprintf(buf);
|
||||
|
||||
return 0;
|
||||
}
|
Loading…
Reference in New Issue
Block a user