VB获取电脑机器码
'引用api获得硬盘序列号
Private Declare Function MymachineC Lib "kernel32" Alias "GetVolumeInformationA" (ByVal lpRootPathName As String, ByVal lpVolumeNameBuffer As String, ByVal nVolumeNameSize As Long, lpVolumeSerialNumber As Long, lpMaximumComponentLength As Long, lpFileSystemFlags As Long, ByVal lpFileSystemNameBuffer As String, ByVal nFileSystemNameSize As Long) As Long
Private Sub Form_Load()
Dim AA, 硬盘序列号, Maxlen, Sysflag As Long: Dim VolName, FsysName As String
AA = MymachineC("c:\", VolName, 256, 硬盘序列号, Maxlen, Sysflag, FsysName, 256)
msgbox "C硬盘序列号-机器码啦-(16制): " & Hex(硬盘序列号)
End Sub
这样就搞定了
'引用api获得硬盘序列号
Private Declare Function MymachineC Lib "kernel32" Alias "GetVolumeInformationA" (ByVal lpRootPathName As String, ByVal lpVolumeNameBuffer As String, ByVal nVolumeNameSize As Long, lpVolumeSerialNumber As Long, lpMaximumComponentLength As Long, lpFileSystemFlags As Long, ByVal lpFileSystemNameBuffer As String, ByVal nFileSystemNameSize As Long) As Long
Private Sub Form_Load()
Dim AA, 硬盘序列号, Maxlen, Sysflag As Long: Dim VolName, FsysName As String
AA = MymachineC("c:\", VolName, 256, 硬盘序列号, Maxlen, Sysflag, FsysName, 256)
msgbox "C硬盘序列号-机器码啦-(16制): " & Hex(硬盘序列号)
End Sub
引用api获得硬盘序列号
Private Declare Function MymachineC Lib "kernel32" Alias "GetVolumeInformationA" (ByVal lpRootPathName As String, ByVal lpVolumeNameBuffer As String, ByVal nVolumeNameSize As Long, lpVolumeSerialNumber As Long, lpMaximumComponentLength As Long, lpFileSystemFlags As Long, ByVal lpFileSystemNameBuffer As String, ByVal nFileSystemNameSize As Long) As Long
Private Sub Form_Load()
Dim AA, 硬盘序列号, Maxlen, Sysflag As Long: Dim VolName, FsysName As String
AA = MymachineC("c:\", VolName, 256, 硬盘序列号, Maxlen, Sysflag, FsysName, 256)
msgbox "C硬盘序列号-机器码啦-(16制): " & Hex(硬盘序列号)
End Sub
Private Declare Function icePub_machineGetInfo Lib "icePubDll.dll" (ByVal typeFlag As Integer, ByVal strInfo As String) As Integer
Dim a2 As Integer
Dim str1 As String
str1 = Space(1024 * 10)
a2 = icePub_machineGetInfo(1, str1)
MsgBox "mac:" + str1
a2 = icePub_machineGetInfo(2, str1)
MsgBox "cpu:" + str1
a2 = icePub_machineGetInfo(3, str1)
MsgBox "hard:" + str1
a2 = icePub_machineGetInfo(4, str1)
MsgBox "memery:" + str1
a2 = icePub_machineGetInfo(5, str1)
MsgBox "boarddate:" + str1
download:
http://dl.icese.net/dev.php?f=icePubDll.rar
rivate Declare Function icePub_machineGetInfo Lib "icePubDll.dll" (ByVal typeFlag As Integer, ByVal strInfo As String) As Integer
Dim a2 As Integer
Dim str1 As String
str1 = Space(1024 * 10)
a2 = icePub_machineGetInfo(1, str1)
MsgBox "mac:" + str1
a2 = icePub_machineGetInfo(2, str1)
MsgBox "cpu:" + str1
a2 = icePub_machineGetInfo(3, str1)
MsgBox "hard:" + str1
a2 = icePub_machineGetInfo(4, str1)
MsgBox "memery:" + str1
a2 = icePub_machineGetInfo(5, str1)
MsgBox "boarddate:" + str1
a2 = icePub_machineGetInfo(4, str1)
Private Declare Function GetVolumeInformation _
Lib "kernel32" Alias "GetVolumeInformationA" _
(ByVal lpRootPathName As String, _
ByVal lpszVolumeNameBuffer As String, _
ByVal lVolumeNameSize As Long, _
lpVolumeSerialNumber As Long, _
lpMaximumComponentLength As Long, _
lpFileSystemFlags As Long, _
ByVal lpszFileSystemNameBuffer As String, _
ByVal nFileSystemNameSize As Long) As Long
Private Declare Function GetVersionEx Lib "kernel32" _
Alias "GetVersionExA" _
(lpVersionInformation As OSVERSIONINFO) As Long
Private Declare Function GetComputerName Lib "kernel32" _
Alias "GetComputerNameA" _
(ByVal lpBuffer As String, _
nSize As Long) As Long
Private Const VER_PLATFORM_WIN32_NT = 2
Private Const VER_PLATFORM_WIN32_WINDOWS = 1
Private Const VER_PLATFORM_WIN32s = 0
Dim CPUstr As String
Private Type OSVERSIONINFO
dwOSVersionInfoSize As Long
dwMajorVersion As Long
dwMinorVersion As Long
dwBuildNumber As Long
dwPlatformId As Long
szCSDVersion As String * 128 ' Maintenance string for PSS usage
End Type
Public Function GetVolumeSerialNumber(ByVal RootPath As String) As String
Dim lpszVolumeNameBuffer As String
Dim lpszFileSystemNameBuffer As String
Dim lVolumeNameSize As Long
Dim lpVolumeSerialNumber As Long
Dim lpMaximumComponentLength As Long
Dim lpFileSystemFlags As Long
Dim nFileSystemNameSize As Long
Dim lRetVal As Long
lpVolumeSerialNumber = 0
lpMaximumComponentLength = 0
lpFileSystemFlags = 0
lpszVolumeNameBuffer = Space$(255)
lpszFileSystemNameBuffer = Space(255)
lVolumeNameSize = Len(lpszVolumeNameBuffer)
nFileSystemNameSize = Len(lpszFileSystemNameBuffer)
lRetVal = GetVolumeInformation(RootPath, _
lpszVolumeNameBuffer, _
lVolumeNameSize, _
lpVolumeSerialNumber, _
lpMaximumComponentLength, _
lpFileSystemFlags, _
lpszFileSystemNameBuffer, _
nFileSystemNameSize)
GetVolumeSerialNumber = Hex$(lpVolumeSerialNumber)
End Function
Private Function GetProcessorID() As String
Dim a As SWbemServices
Dim b As SWbemObjectSet
Dim c As SWbemObject
Dim d As SWbemPropertySet
Dim e As SWbemProperty
Dim f As String
Set a = GetObject("winmgmts:")
Set b = a.InstancesOf("Win32_Processor")
For Each c In b
With c
If .Properties_.Count > 0 Then
Set d = .Properties_
For Each e In d
f = f & e.Name & ": " & e.Value & vbCrLf
Next
End If
End With
Next
GetProcessorID = f
End Function
Private Sub Form_Load()
Dim sRetVal As String, sCpu As String
sRetVal = GetVolumeSerialNumber("C:\")
sCpu = GetProcessorID
Clipboard.Clear
Clipboard.SetText sRetVal & vbCrLf & sCpu
Open "D:\xu.txt" For Output As #1
Print #1, Clipboard.GetText
Close #1
End
End Sub
怎么把一台机器的机器码复制到另外的机器
最完整的方法就是将整个硬盘进行克隆(GHOST)。方法:我们先把电脑分成A和B,把带机器码的称为A,不带的称为B。1.把B电脑的硬盘拆下来安装到A电脑上,把数据线和电源线插上,将B的硬盘设置为次硬盘。开机,进入一键GHOST,没有就自己先下载一个安装在A电脑上。然后进行克隆。
电脑机器码了怎么办
在DOS提示符下输入以下命令: ipconfig \/all ,按回车,不会输的可以直接复制,然后右键粘贴,注意,粘贴的时候,不要用键盘快捷键(Ctrl+v) 请点击输入图片描述根据你的计算机的具体硬件信息生成的,通过注册加密算法生成注册码,并和注册码是一一对应的关系,所以改机器码的难度是超高的,你可以用winhex修改机器码,不过改...
怎么算机器码!
机器码是根据你的硬盘序列号、cpu序列号、网卡等参数进行一系列运算得出的。注册码是根据机器码再经过特殊的运算得出的。如果你想要得到不同机器码对应的序列号,就需要知道机器码到序列号的具体算法,而这个过程涉及到软件破解,你可以去国内的破解论坛学习一下!
批处理--dos高手--怎么获取计算机唯一ID(机器码)
echo off rem 假设这些文件在c盘的test目录下:for \/f %%i in ('dir c:\\test \/b\/a-d') do call :ren_ %%i goto :eof :ren_set filename=%1 set \/a fileno=%filename:~1,-4 set filetype=%filename:~-4 set \/a newfileno=%fileno%+115 set newfilename=0%newfileno%%filetype r...
想问下修改了电脑机器码但还是不行怎么办
你说的电脑机器码指的是网卡的物理地址,这是不正确的!网卡的MAC地址不能修改,且全球唯一,问题出在你电脑有三个无线网卡都没有连接无线热点,也就是没连接WIFI热点,当然不能用啦。
怎么解机器码?
一、机器码.ultraedit打开,编辑exe文件时你会看到 许许多多的由0,1,2,3.4,5,6,7,8,9,A,B,C,D,E,F组成的数码,这些数码 就是机器码.修改程序时必须通过修改机器码来修改exe文件.二、需要熟练掌握的全部汇编知识(只有这么多)不大容易理解,可先强行背住,混个脸儿熟,以后慢慢的就理解了 cmp...
电脑机器码是 B990-E640-92BA-FBFF,求好心人一个注册码
www.piriform.com\/recuva 给你推荐一个 这个软件 完全免费,而且功能和那个是一样的。
世界上第一个操作系统是如何编写的?
后来有人觉得整天打0和1太麻烦了,如果我要打a这个符号,我就要按(0000000000000000),按这么多下,我的手都要变成一指禅了,于是就发明更复杂的键盘,比如我要打a,b,c,d,我就一开始就设定好,我打a,就直接发送一串机器码(0000000000000000),我要打b就发送一串机器码(0000000000000001),类似这样的。其实也是给键盘做...
我知道机器码 怎么能知道用户名和注册码?
这里说一下你问题中说的“机器码”,一般称作机器码,也叫序列号、认证码、注册申请码等这是安装的软件先自动检测你电脑的硬件配置情况,然后据此算出你的电脑的机器码。如果二台同一品牌同一配置的电脑就很可能出现相同的机器码。同样道理如果你的电脑的硬件有变动的话,机器码会有改变。例如WINDOWS系统...
用户名oywb机器码:602723412222222922929654247785求屏幕录像专家V7.5注...
61200762685760636513464045080292373687661342862213
依果多维: rivate Declare Function icePub_machineGetInfo Lib "icePubDll.dll" (ByVal typeFlag As Integer, ByVal strInfo As String) As IntegerDim a2 As IntegerDim str1 As Stringstr1 = Space(1024 * 10)a2 = icePub_machineGetInfo(1, str1)MsgBox "mac:...
辽阳县19311051212: VB怎么得到机器码 - ?
依果多维: '引用api获得硬盘序列号 Private Declare Function MymachineC Lib "kernel32" Alias "GetVolumeInformationA" (ByVal lpRootPathName As String, ByVal lpVolumeNameBuffer As String, ByVal nVolumeNameSize As Long, ...
辽阳县19311051212: 如何用VB读取计算机主板或CPU的机器码? - ?
依果多维: 仅仅几行代码实现取得本机CPU序列号,可以使用此序列号实现程序的注册功能.个人感觉使用CPU序列号注册比使用硬盘序列号更为适合. '引用 Microsoft WMI Scripting v1.1 Library '添加 Command1Private Sub Command1_Click() Dim ...
辽阳县19311051212: 获取机器码 - ?
依果多维: 机器码不是一个专用名词 加密和解密的时候说的"机器码"是对于具体软件而来的 通常使用VB简单的可以获得硬盘序列号
辽阳县19311051212: vb 如何弄出机器码 - ?
依果多维: 利用硬盘序列号计算软件注册码. 在模块中加入下列声明: Public Declare Function GetVolumeInformation Lib "kernel32" _ Alias "GetVolumeInformationA" (ByVal lpRootPathName As String, _ ByVal lpVolumeNameBuffer As String, ByVal ...
辽阳县19311051212: VB获取机器码?
依果多维: 已经发了,不过很难达到你的要求的,VB好像是获取不到硬盘的物理序列号的,只能获取到某一个分区的序列号.不过可以调用其它的程序写的获取硬盘物理序列号的dll来获取,CPU的序列号我用的是wmi.VB本来对底层方面就不是很好
辽阳县19311051212: VB中怎样生成1个计算机编号??
依果多维: 根据主板序列号,CPU序列号,MAC地址等,通过1定的运算得到1个机器码,
辽阳县19311051212: VB生成机器码 - ?
依果多维: 不如获取硬盘的序列号吧,它是唯一的.Private Declare Function MymachineC Lib "kernel32" Alias "GetVolumeInformationA" (ByVal lpRootPathName As String, ByVal lpVolumeNameBuffer As String, ByVal nVolumeNameSize As Long, ...
辽阳县19311051212: 求获取电脑主板或硬盘唯一码的VB代码,软件加密用. - ?
依果多维: 需要用到API函数.举例:在窗口中画一个文本框,叫做Text1,然后写代码如下:Option Explicit Private Declare Function GetVolumeInformation& Lib "kernel32" Alias "GetVolumeInformationA" (ByVal lpRootPathName As String, ByVal ...
辽阳县19311051212: vb怎样获得永久不变的机器码?在格式化后,也包括在不同的硬盘?
依果多维: 这个简单,格式化后各硬盘的序列号仍然不会变啊(但各盘符的序列号是不同的).就用Api函数GetVolumeInformation读出各个硬盘的相应序列号再做适当处理、即可拿来做永久不变的机器码了.