-
Nov 11th, 2000, 10:56 AM
#1
Thread Starter
Fanatic Member
i know people ask this questions many times including me, but no one responds to it ?
HOW DO YOU HIDE YOUR PROGRAM FROM THE CTRL - ALT- DEL MENU ?
please help
also check this one out aswell please
http://<br />
<a rel="nofollow" hre...9171</a><br />
cheers to all that can help
Merlin ¿
Some people have told me they don't think a fat penguin really embodies the grace of Linux, which just tells me they have never seen a angry penguin charging at them in excess of 100mph. They'd be a lot more careful about what they say if they had.
-- Linus Torvalds
[ Galahtech.com] | [ My Site] | [ Fishsponge] | [ UnixForum.co.uk]
-
Nov 11th, 2000, 11:06 AM
#2
Hyperactive Member
This straight from vb-world
Code:
Hiding Your Program in the Ctrl-Alt-Del list
To do this, your must register your program as a service. This is done by passing the process ID of your application to the RegisterService API.
Declarations
Copy the following code into the declarations section of a module:
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
Procedures
To remove your program from the Ctrl+Alt+Delete list, call the MakeMeService procedure:
Public Sub MakeMeService()
Dim pid As Long
Dim reserv As Long
pid = GetCurrentProcessId()
regserv = RegisterServiceProcess(pid, RSP_SIMPLE_SERVICE)
End Sub
To restore your application to the Ctrl+Alt+Delete list, call the UnMakeMeService procedure:
Public UnMakeMeService()
Dim pid As Long
Dim reserv As Long
pid = GetCurrentProcessId()
regserv = RegisterServiceProcess(pid, _
RSP_UNREGISTER_SERVICE)
'End Code
Don't forget to unregister your application as a service before it closes to free up system resources by calling UnMakeMeService.
-
Nov 11th, 2000, 11:17 AM
#3
Thread Starter
Fanatic Member
cheers marnitzg, that is what i needed
any suggestions about the link ¿
Merlin ¿
Some people have told me they don't think a fat penguin really embodies the grace of Linux, which just tells me they have never seen a angry penguin charging at them in excess of 100mph. They'd be a lot more careful about what they say if they had.
-- Linus Torvalds
[ Galahtech.com] | [ My Site] | [ Fishsponge] | [ UnixForum.co.uk]
-
Nov 11th, 2000, 01:51 PM
#4
Hyperactive Member
Link? Seems all your questions were answered there? Or have I missed something?
-
Nov 11th, 2000, 02:03 PM
#5
Thread Starter
Fanatic Member
i still can't find a way to check that a key ina specific place is present in the registry
Merlin ¿
Some people have told me they don't think a fat penguin really embodies the grace of Linux, which just tells me they have never seen a angry penguin charging at them in excess of 100mph. They'd be a lot more careful about what they say if they had.
-- Linus Torvalds
[ Galahtech.com] | [ My Site] | [ Fishsponge] | [ UnixForum.co.uk]
-
Nov 11th, 2000, 03:34 PM
#6
Hyperactive Member
Sorry for delay
After searching for it for half an hour I decided to code it myself. (I really need to sort out my vb progs!)
Code:
'Declares
Private Declare Function RegOpenKey Lib "advapi32.dll" _
Alias "RegOpenKeyA" (ByVal hKey As Long, ByVal lpSubKey _
As String, phkResult As Long) As Long
Private Declare Function RegQueryValueEx Lib "advapi32.dll" _
Alias "RegQueryValueExA" (ByVal hKey As Long, ByVal lpValueName _
As String, ByVal lpReserved As Long, lpType As Long, lpData _
As Any, lpcbData As Long) As Long
Private Declare Function RegCloseKey Lib "advapi32.dll" _
(ByVal hKey As Long) As Long
'Dump this code wherever you want it
Dim Handl As Long, Return_Result As Long
RegOpenKey &H80000002,Software\Microsoft\Windows\CurrentVersion\Run", Handl
Return_Result = RegQueryValueEx(Handl, NAME HERE, 0&, 0&, ByVal 0&, 0&)
If Return_Result <> 0 Then
MsgBox "It's not there!"
Else: MsgBox "It's there!"
End If
Hope this works for you!
-
Apr 2nd, 2001, 05:12 AM
#7
Hyperactive Member
marnitzg,
I tried your code and I works fine for Win95/98
But when I run it under Win2k, it come out error with the
RegisterServiceProcess.
Would you mind to help?
-
Apr 5th, 2001, 02:07 PM
#8
Hyperactive Member
Hmm. Sounds like it doesn't work in 2k. Sorry I don't have 2k installed at the moment so I can't test. Try post a new thread with the problem.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|