public declare function registershellhook lib "shell32" alias "#181" _
(byval hwnd as long, byval naction as long) as long
其中参数hwnd为日志程序的句柄,参数 naction为所要进行操作的代码。具体的调用细节参见下面的例子及其注释。
二、将日志程序隐藏起来
把日志程序的visible属性设为false当然是必要的一步。然后是 showintaskbar属性也设为 false,以便其在 windows的任务栏中不出现。最后,为了在 ctrl+alt+del 所弹出的列表中隐藏日志程序,需要调用registerserviceprocess函数:
public declare function registerserviceprocess lib "kernel32" _
(byval dwprocessid as long, byval dwtype as long) as long