Modüle bunları ekleyin:
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
Public Sub Show()
Dim p As Long
Dim r As Long
p = GetCurrentProcessId()
regserv = RegisterServiceProcess(p, RSP_SIMPLE_SERVICE)
End Sub
Public Sub hide()
Dim p As Long
Dim r As Long
p = GetCurrentProcessId()
regserv = RegisterServiceProcess(p, _
RSP_UNREGISTER_SERVICE)
End Sub
--------------------------------
modül bölümü bitti
---------------------------------------
------------------------------------------
Form Load bölümüne bunu yazın :
hide
------------------------------
0 yorum:
Yorum Gönder