nizarazou87
10th May 2011, 12:46
Hi,
I developed a program using Visual C++ that contain a thread and i want to integrate him in a QT project to interact with a graphical interface.
The problem is that i created the interface in a thread and i called it in the main function then i used the function that i have developed in VC++ that launch my other thread, the program do not creat this one and run only the interface.
My main function:
void main(int argc, char *argv[])
{
MyThread Window;
C_DlmsManager Stack;
Window.run();
Stack.Start();
}
The function that launch my thread:
static DWORD WINAPI LaunchStack(LPVOID pvParam)
{
C_DlmsManager* pPile = (C_DlmsManager*)pvParam;
(*pPile).Initialize();
(*pPile).Manager();
return 1;
}
I developed a program using Visual C++ that contain a thread and i want to integrate him in a QT project to interact with a graphical interface.
The problem is that i created the interface in a thread and i called it in the main function then i used the function that i have developed in VC++ that launch my other thread, the program do not creat this one and run only the interface.
My main function:
void main(int argc, char *argv[])
{
MyThread Window;
C_DlmsManager Stack;
Window.run();
Stack.Start();
}
The function that launch my thread:
static DWORD WINAPI LaunchStack(LPVOID pvParam)
{
C_DlmsManager* pPile = (C_DlmsManager*)pvParam;
(*pPile).Initialize();
(*pPile).Manager();
return 1;
}