I am making a dll file and at the same time trying to call this function automatically when my DLL is loaded. How can I do this? It is a Windows API main function that creates a window but I dont know how do it. My first idea is to put it into DllMain function but I am really sure if this will work and also what to fill in the variables "HINSTANCE hInstance, HINSTANCE hPrevInstance,LPSTR lpCmdLine, int nCmdShow"
Below is the function I am trying to call automatically when my dll is loaded and I expect it to open a Window. Thanks.
int WINAPI WinMain(HINSTANCE hInstance, HINSTANCE hPrevInstance,LPSTR lpCmdLine, int nCmdShow);