Index   Commented   Search   About

InitInstance

The InitInstance function initializes all data structures for the program instance and creates the necessary windows. InitInstance looks like a standard Windows initialization function except that it calls the InstallRecognizer function to load the default recognizer SREC. Windows loads the default recognizer automatically, so a program should call InstallRecognizer to load only recognizers other than the default recognizer.

The following fragment taken from the InitInstance function shows how the program loads the SREC recognizer:

BOOL InitInstance(

HANDLE hInstance, // Instance handle

int cmdShow ) // ShowWindow flag

{

.

.

.

//

// Load sample recognizer SREC

//

  • hrec = InstallRecognizer( (LPSTR) szSampleRec );

if (vhrec)

return TRUE;

else

{

MessageBox( vhwndMain, "Could not install recognizer SREC",

szPenAppWnd, MB_OK | MB_ICONSTOP );

return FALSE;

}

}

Related Links

Software for Delphi and C++ Builder developers
Software for Visual Studio .NET developers
Software for Visual Basic 6 developers
Delphi Tips&Tricks
MegaDetailed.NET

More Online Helps

Win32 Programmer's Reference (win32.hlp)
Win32 Multimedia Programmer's Reference (mmedia.hlp)
OLE Programmer's Reference (ole.hlp)
Microsoft Windows Sockets 2 Reference (sock2.hlp)
Microsoft Windows Telephony API (TAPI) Programmer's Reference (tapi.hlp)
Unix Manual Pages

Free Tech Secrets ;) Copyright © 2008 Free Tect Secrets ;) greatis just4fun network just4fun