Programmatically start touch screen calibration

by Krishnaraj Varma on August 23, 2009

in Windows Mobile

The following link explains the Touch Screen Driver functions. Since we cannot directly call these function using Windows Mobile SDK, we have to load the CoreDll.dll file and call these function dynamically. The following code snippet start the Touch Screen calibration programmatically.

typedef BOOL (WINAPI* pfnTouchCalibrate)(void)
int _tmain(int argc, _TCHAR* argv[])
{
	HMODULE hCoreDLL = LoadLibrary(_T("coredll.dll"));
	pfnTouchCalibrate pTouchCalibrate = (pfnTouchCalibrate)GetProcAddress(hCoreDLL, _T("TouchCalibrate"));
	if (pTouchCalibrate)
		pTouchCalibrate();
	FreeLibrary(hCoreDLL);
}

Previous post:

Next post:

Disclaimer: This is a personal weblog. The information in this weblog is provided “AS IS” with no warranties, and confers no rights. This weblog does not represent the thoughts, intentions, plans or strategies of my employer. It is solely my opinion.