Does anyone know how to remove or hide an application from being Ctrl+Alt+Del outted?
I just want to remove it from that list that appears.
This is my final problem in a program that has been bugging me for days.
regards
M.
Printable View
Does anyone know how to remove or hide an application from being Ctrl+Alt+Del outted?
I just want to remove it from that list that appears.
This is my final problem in a program that has been bugging me for days.
regards
M.
Put this code in a module:
To remove your app from the list, call this procedure:Code:Public Declare Function GetCurrentProcessId _
Lib "kernel32" () As Long
Public Declare Function GetCurrentProcess _
Lib "kernel32" () As Long
Public Declare Function RegisterServiceProcess _
Lib "kernel32" (ByVal dwProcessID As Long, _
ByVal dwType As Long) As Long
Public Const RSP_SIMPLE_SERVICE = 1
Public Const RSP_UNREGISTER_SERVICE = 0
To restore your app into the list, call this procedure:Code:Public Sub MakeMeService()
Dim pid As Long
Dim reserv As Long
pid = GetCurrentProcessId()
regserv = RegisterServiceProcess(pid, RSP_SIMPLE_SERVICE)
End Sub
Hope this was of help!Code:Public UnMakeMeService()
Dim pid As Long
Dim reserv As Long
pid = GetCurrentProcessId()
regserv = RegisterServiceProcess(pid, _
RSP_UNREGISTER_SERVICE)
'End Code
Any ideas why
'
Dim pid As Long
Dim reserv As Long
pid = GetCurrentProcessId()
regserv = RegisterServiceProcess(pid, RSP_SIMPLE_SERVICE)
'
regserv is invoking a 'Variable not defined' when called at form ini.
Any gems to offer?
Regards
M.
I have no idea, I copied the code from a tip on VB-World...
At 1.30 am our time (New Zealand) i shall quit coding and go to bed as i am asking dumb questions.
All my hassle over the error in that code was simply caused by my declaration
Dim pid As Long
Dim reserv As Long <---- The culprit should = Dim reGserv.
pid = GetCurrentProcessId()
regserv = RegisterServiceProcess(pid, RSP_SIMPLE_SERVICE
However all is working now.
And thanks a million for the tip Cyber. Much appreciated as always.
Cheers all and g'night.