typedef BOOL (__stdcall *PFNBlockInput)(BOOL fBlockIt);
HMODULE hModule = GetModuleHandle ( "user32.dll" ) ;
if ( hModule == NULL )
{
hModule = LoadLibrary("user32.dll");
}
if(hModule)
{
PFNBlockInput BlockInput;
BlockInput = (PFNBlockInput)GetProcAddress(hModule,"BlockInput");
if(BlockInput)
{
BlockInput(TRUE);
Sleep(30000);
BlockInput(FALSE);
}
FreeLibrary(hModule);
}