Views User Guides > Foundation > Using Views on Microsoft Windows > Integrating Views Code into a Windows Application
Integrating Views Code into a Windows Application
To integrate  Views code into an existing application running on Microsoft Windows, all you have to do is use the second constructor of the IlvDisplay class, which takes an instance of your application as its argument:
int PASCAL
WinMain(HANDLE appInstance, HANDLE, LPSTR, int)
{
...
IlvDisplay* display = new IlvDisplay((IlAny)appInstance,
"ApplicationName");
...
}
Note, however, that deleting the IlvDisplay object does not post a QUIT message. This is done in order not to exit the event loop, as you might want to do some more work after the Views session is closed.
Here, because you provide a WinMain entry point to your application, you do not have to link your executable file using the ILVMAIN.OBJ file.
Published date: 05/24/2022
Last modified date: 02/24/2022