Skip to content

Instantly share code, notes, and snippets.

@jdferrell3
Created April 4, 2019 23:38
Embed
What would you like to do?
#ifndef UNICODE
#define UNICODE
#endif
#include<windows.h>
int WINAPI wWinMain(HINSTANCE hinstance, HINSTANCE hprevinstance, PWSTR szCmdLine, int nCmdShow)
{
wchar_t path[256];
DWORD size = 256;
GetModuleFileNameW(
NULL,
path,
size);
MessageBox(NULL, path, L"Full Path", MB_OK);
return 0;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment