发表评论(0)作者:, 平台:, 阅读:13249, 日期:2000-03-12
确定是 WINDOWS 的可执行文件 98-6-17
在文件的第 24 字节,如果为40h,就是 Windows 的可执行文件。
Function WinExe (ByVal Exe As String) As Integer
Dim fh As Integer
Dim t As String * 1
fh = FreeFile
Open Exe For Binary As #fh
Get fh, 25, t
Close #fh
WinExe = (Asc(t) = &H40&)
End Function
在文件的第 24 字节,如果为40h,就是 Windows 的可执行文件。
Function WinExe (ByVal Exe As String) As Integer
Dim fh As Integer
Dim t As String * 1
fh = FreeFile
Open Exe For Binary As #fh
Get fh, 25, t
Close #fh
WinExe = (Asc(t) = &H40&)
End Function