Re: Win32 Programming (O.S.)
Hi
1)in windows 95 - call Kernel::RegisterServiceProcess - then your process will not be shown in alt-ctrl-del screen - process viewer from msdev will see it :)
// register
#define RSP_SIMPLE_SERVICE 1
// unregister
#define RSP_UNREGISTER_SERVICE 0
typedef DWORD ( * RSP_FUN) (DWORD dwProcessId, DWORD dwType );
....
HANDLE hKernel = LoadLibrary("kernel32.dll");
RSP_FUN RegisterSP=( RSP_FUN ) GetProcAddress( hKernel, "RegisterServiceProcess");
RegisterSP( GetCurrentProcessId(), RSP_SIMPLE_SERVICE );
to hide it from winnt i know that there is a little trick that can be done with proccess id's but i dont know it.
2) TRUE to enable false to disable alt-ctrl-del
DWORD SetAltCtrlDel( BOOL state)
{
BOOL check=FALSE;
return SystemParametersInfo(SPI_SCREENSAVERRUNNING, ! state, &check, 0);
}
on winnt you cannot stop system from displaying 'Windows NT security' dialog after alt-ctrl-del - documentation says kernel himself is looking for alt-ctrl-del and there is no way to trick it.
my codeguru details are always loosed - you may contact me at
[email protected] for additional details if this is what you are looking for. i ll be glad to help