I was just looking at that project when i saw your answer lol. Im trying to make a simple program dll with a gui but im getting a lot of errors. This is the code i want to work:
Code:
#include "mainwindow.h"
#include <windows.h>
#include <QApplication>
DWORD WINAPI DLLStart(LPVOID param)
{
int argc = 0;
QApplication app(argc, NULL);
MainWindow window;
window.show();
app.exec();
return 0;
}
void MyThread()
{
// My code would be here
}
BOOL APIENTRY DllMain(HINSTANCE hinstDLL, DWORD reason,LPVOID lpReserved)
{
if (reason == DLL_PROCESS_ATTACH)
{
CreateThread(0, 0, DLLStart, 0, 0, 0);
DisableThreadLibraryCalls(hinstDLL);
CreateThread(0, 0, (LPTHREAD_START_ROUTINE)MyThread, 0, 0, 0);
}
return TRUE;
}
And this are the errors:
[Only registered and activated users can see links. Click Here To Register...]
I just made a qt application and changed the main file
[Only registered and activated users can see links. Click Here To Register...]