On Wednesday, 29 April 2020 at 10:46:30 UTC, Mike Parker wrote:
On Wednesday, 29 April 2020 at 10:44:48 UTC, Mike Parker wrote:

Yeah, it says "WinMain is needed", which has never been true.

THere's no need for the def file either.

What's the way to get the hInstance without the use of WinMain?

From Microsoft documentation:
hInstance is the handle to the application instance. Get this value from the hInstance parameter of wWinMain.

https://docs.microsoft.com/en-us/windows/win32/learnwin32/creating-a-window

I cannot find a D example using Win32 and the normal main function, and while it is working for simple message boxes, as soon as I want to do something slightly more complex (using a window), an hInstance has to be provided (as far as I understand, I'm not that knowledgeable with Win32).

Reply via email to