tamam başka ne kaldı onu anlamadım. mac adreslerini ftp adresine kaydedersin ve bu şekilde mac adresini bulup veritabanında olup olmadığını kontrol edersin eğer ftp adresinde varsa programı açtırırsın.

arkadaşım yanlış anladın beni.. tamam bende bu program var, ben bu programı kişiye atıcam adam bana serial no sunu sölicek bunu kendi projeme eklicem adama atıcam.. sadece o adamda çalışacak program ben bunu istiyorum?

slmlar beyler telaffuzunu nasıl yapayım bilmiyom ama kabaca anlatayım.. kendi yazdığım bi program var bunu sadece 1stClass için yazdım onlardan başkası kullanamasın diye ya HDD serial no larını alıcam programa eklip öle vericem yada Mac Adreslerini alip programa eklicem öle vericem.. yani amacım programın sadece o pc de çalışması vb6 kullanıyorum, Lütfen yardım ediniz sabahlara kadar yazdım gözüm şişti emeğim sadece 1stclass... başka sitelere yayılsa bile kullanamasınlar şimdiden tskler :innocent:

HDD serial no: Command botton (command1) ve list box (list1) ekleyiniz. Kod: Option Explicit '''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''' ' Copyright ©1996-2009 VBnet, Randy Birch, All Rights Reserved. ' Some pages may also contain other copyrights by the author. '''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''' ' Distribution: You can freely use this code in your own ' applications, but you may not reproduce ' or publish this code on any web site, ' online service, or distribute as source ' on any media without express permission. '''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''' Private Const GENERIC_READ = &H80000000 Private Const GENERIC_WRITE = &H40000000 Private Const FILE_SHARE_READ = &H1 Private Const FILE_SHARE_WRITE = &H2 Private Const OPEN_EXISTING = 3 Private Const CREATE_NEW = 1 Private Const INVALID_HANDLE_VALUE = -1 Private Const VER_PLATFORM_WIN32_NT = 2 Private Const IDENTIFY_BUFFER_SIZE = 512 Private Const OUTPUT_DATA_SIZE = IDENTIFY_BUFFER_SIZE + 16 'GETVERSIONOUTPARAMS contains the data returned 'from the Get Driver Version function Private Type GETVERSIONOUTPARAMS bVersion As Byte 'Binary driver version. bRevision As Byte 'Binary driver revision bReserved As Byte 'Not used bIDEDeviceMap As Byte 'Bit map of IDE devices fCapabilities As Long 'Bit mask of driver capabilities dwReserved(3) As Long 'For future use End Type 'IDE registers Private Type IDEREGS bFeaturesReg As Byte 'Used for specifying SMART "commands" bSectorCountReg As Byte 'IDE sector count register bSectorNumberReg As Byte 'IDE sector number register bCylLowReg As Byte 'IDE low order cylinder value bCylHighReg As Byte 'IDE high order cylinder value bDriveHeadReg As Byte 'IDE drive/head register bCommandReg As Byte 'Actual IDE command bReserved As Byte 'reserved for future use - must be zero End Type 'SENDCMDINPARAMS contains the input parameters for the 'Send Command to Drive function Private Type SENDCMDINPARAMS cBufferSize As Long 'Buffer size in bytes irDriveRegs As IDEREGS 'Structure with drive register values. bDriveNumber As Byte 'Physical drive number to send command to (0,1,2,3). bReserved(2) As Byte 'Bytes reserved dwReserved(3) As Long 'DWORDS reserved bBuffer As Byte 'Input buffer. End Type 'Valid values for the bCommandReg member of IDEREGS. Private Const IDE_ID_FUNCTION = &HEC 'Returns ID sector for ATA. Private Const IDE_EXECUTE_SMART_FUNCTION = &HB0 'Performs SMART cmd. 'Requires valid bFeaturesReg, 'bCylLowReg, and bCylHighReg 'Cylinder register values required when issuing SMART command Private Const SMART_CYL_LOW = &H4F Private Const SMART_CYL_HI = &HC2 'Status returned from driver Private Type DRIVERSTATUS bDriverError As Byte 'Error code from driver, or 0 if no error bIDEStatus As Byte 'Contents of IDE Error register 'Only valid when bDriverError is SMART_IDE_ERROR bReserved(1) As Byte dwReserved(1) As Long End Type Private Type IDSECTOR wGenConfig As Integer wNumCyls As Integer wReserved As Integer wNumHeads As Integer wBytesPerTrack As Integer wBytesPerSector As Integer wSectorsPerTrack As Integer wVendorUnique(2) As Integer sSerialNumber(19) As Byte wBufferType As Integer wBufferSize As Integer wECCSize As Integer sFirmwareRev(7) As Byte sModelNumber(39) As Byte wMoreVendorUnique As Integer wDoubleWordIO As Integer wCapabilities As Integer wReserved1 As Integer wPIOTiming As Integer wDMATiming As Integer wBS As Integer wNumCurrentCyls As Integer wNumCurrentHeads As Integer wNumCurrentSectorsPerTrack As Integer ulCurrentSectorCapacity As Long wMultSectorStuff As Integer ulTotalAddressableSectors As Long wSingleWordDMA As Integer wMultiWordDMA As Integer bReserved(127) As Byte End Type 'Structure returned by SMART IOCTL commands Private Type SENDCMDOUTPARAMS cBufferSize As Long 'Size of Buffer in bytes DRIVERSTATUS As DRIVERSTATUS 'Driver status structure bBuffer As Byte 'Buffer of arbitrary length for data read from drive End Type 'Vendor specific feature register defines 'for SMART "sub commands" Private Const SMART_ENABLE_SMART_OPERATIONS = &HD8 'Status Flags Values Public Enum STATUS_FLAGS PRE_FAILURE_WARRANTY = &H1 ON_LINE_COLLECTION = &H2 PERFORMANCE_ATTRIBUTE = &H4 ERROR_RATE_ATTRIBUTE = &H8 EVENT_COUNT_ATTRIBUTE = &H10 SELF_PRESERVING_ATTRIBUTE = &H20 End Enum 'IOCTL commands Private Const DFP_GET_VERSION = &H74080 Private Const DFP_SEND_DRIVE_COMMAND = &H7C084 Private Const DFP_RECEIVE_DRIVE_DATA = &H7C088 Private Type ATTR_DATA AttrID As Byte AttrName As String AttrValue As Byte ThresholdValue As Byte WorstValue As Byte StatusFlags As STATUS_FLAGS End Type Private Type DRIVE_INFO bDriveType As Byte SerialNumber As String Model As String FirmWare As String Cilinders As Long Heads As Long SecPerTrack As Long BytesPerSector As Long BytesperTrack As Long NumAttributes As Byte Attributes As ATTR_DATA End Type Private Enum IDE_DRIVE_NUMBER PRIMARY_MASTER PRIMARY_SLAVE SECONDARY_MASTER SECONDARY_SLAVE TERTIARY_MASTER TERTIARY_SLAVE QUARTIARY_MASTER QUARTIARY_SLAVE End Enum Private Declare Function CreateFile Lib "kernel32" _ Alias "CreateFileA" _ As Long Private Declare Function CloseHandle Lib "kernel32" _ As Long Private Declare Function DeviceIoControl Lib "kernel32" _ As Long Private Declare Sub CopyMemory Lib "kernel32" _ Alias "RtlMoveMemory" _ Private Type OSVERSIONINFO OSVSize As Long dwVerMajor As Long dwVerMinor As Long dwBuildNumber As Long PlatformID As Long szCSDVersion As String 128 End Type Private Declare Function GetVersionEx Lib "kernel32" _ Alias "GetVersionExA" _ As Long Private Sub Form_Load Command1. Caption = "Get Drive Info" End Sub Private Sub Command1_Click Dim di As DRIVE_INFO Dim drvNumber As Long For drvNumber = PRIMARY_MASTER To QUARTIARY_SLAVE di = GetDriveInfo List1. AddItem "Drive " & drvNumber With di Select Case. bDriveType Case 0 List1. AddItem vbTab & " " Case 1 List1. AddItem vbTab & "Model:" & vbTab & Trim$ List1. AddItem vbTab & "Serial No:" & vbTab & Trim$ Case 2 List1. AddItem vbTab & " " Case Else List1. AddItem vbTab & " " End Select End With Next End Sub Private Function GetDriveInfo As DRIVE_INFO Dim hDrive As Long Dim di As DRIVE_INFO hDrive = SmartOpen If hDrive <> INVALID_HANDLE_VALUE Then If SmartGetVersion = True Then With di. bDriveType = 0. NumAttributes = 0 ReDim. Attributes(0) . bDriveType = 1 End With If SmartCheckEnabled Then If IdentifyDrive = True Then GetDriveInfo = di End If 'IdentifyDrive End If 'SmartCheckEnabled End If 'SmartGetVersion End If 'hDrive <> INVALID_HANDLE_VALUE CloseHandle hDrive End Function Private Function IdentifyDrive As Boolean 'Function: Send an IDENTIFY command to the drive 'drvNumber = 0-3 'IDCmd = IDE_ID_FUNCTION or IDE_ATAPI_ID Dim SCIP As SENDCMDINPARAMS Dim IDSEC As IDSECTOR Dim bArrOut(OUTPUT_DATA_SIZE - 1) As Byte Dim cbBytesReturned As Long With SCIP. cBufferSize = IDENTIFY_BUFFER_SIZE. bDriveNumber = CByte With. irDriveRegs. bFeaturesReg = 0. bSectorCountReg = 1. bSectorNumberReg = 1. bCylLowReg = 0. bCylHighReg = 0. bDriveHeadReg = &HA0 'compute the drive number If Not IsWinNT4Plus Then. bDriveHeadReg = . bDriveHeadReg Or ((drvNumber And 1) 16) End If 'the command can either be IDE 'identify or ATAPI identify. . bCommandReg = CByte End With End With If DeviceIoControl(hDrive, _ DFP_RECEIVE_DRIVE_DATA, _ SCIP, _ Len - 4, _ bArrOut(0), _ OUTPUT_DATA_SIZE, _ cbBytesReturned, _ ByVal 0&) Then CopyMemory IDSEC, bArrOut(16), Len di. Model = StrConv(SwapBytes , vbUnicode) di. SerialNumber = StrConv(SwapBytes , vbUnicode) IdentifyDrive = True End If End Function Private Function IsWinNT4Plus As Boolean 'returns True if running Windows NT4 or later Dim osv As OSVERSIONINFO osv. OSVSize = Len If GetVersionEx = 1 Then IsWinNT4Plus = (osv. PlatformID = VER_PLATFORM_WIN32_NT) And _ (osv. dwVerMajor >= 4) End If End Function Private Function SmartCheckEnabled As Boolean 'SmartCheckEnabled - Check if SMART enable 'FUNCTION: Send a SMART_ENABLE_SMART_OPERATIONS command to the drive 'bDriveNum = 0-3 Dim SCIP As SENDCMDINPARAMS Dim SCOP As SENDCMDOUTPARAMS Dim cbBytesReturned As Long With SCIP. cBufferSize = 0 With. irDriveRegs. bFeaturesReg = SMART_ENABLE_SMART_OPERATIONS. bSectorCountReg = 1. bSectorNumberReg = 1. bCylLowReg = SMART_CYL_LOW. bCylHighReg = SMART_CYL_HI. bDriveHeadReg = &HA0 If Not IsWinNT4Plus Then. bDriveHeadReg = . bDriveHeadReg Or ((drvNumber And 1) 16) End If. bCommandReg = IDE_EXECUTE_SMART_FUNCTION End With. bDriveNumber = drvNumber End With SmartCheckEnabled = DeviceIoControl(hDrive, _ DFP_SEND_DRIVE_COMMAND, _ SCIP, _ Len - 4, _ SCOP, _ Len - 4, _ cbBytesReturned, _ ByVal 0&) End Function Private Function SmartGetVersion As Boolean Dim cbBytesReturned As Long Dim GVOP As GETVERSIONOUTPARAMS SmartGetVersion = DeviceIoControl(hDrive, _ DFP_GET_VERSION, _ ByVal 0&, 0, _ GVOP, _ Len , _ cbBytesReturned, _ ByVal 0&) End Function Private Function SmartOpen As Long 'Open SMART to allow DeviceIoControl 'communications and return SMART handle If IsWinNT4Plus Then SmartOpen = CreateFile("\\.\PhysicalDrive" & CStr , _ GENERIC_READ Or GENERIC_WRITE, _ FILE_SHARE_READ Or FILE_SHARE_WRITE, _ ByVal 0&, _ OPEN_EXISTING, _ 0&, _ 0&) Else SmartOpen = CreateFile("\\.\SMARTVSD", _ 0&, 0&, _ ByVal 0&, _ CREATE_NEW, _ 0&, _ 0&) End If End Function Private Function SwapBytes(b As Byte) As Byte 'Note: VB4-32 and VB5 do not support the 'return of arrays from a function. For 'developers using these VB versions there 'are two workarounds to this restriction: ' '1) Change the return data type ( As Byte ) ' to As Variant . No change ' to the calling code is required. ' '2) Change the function to a sub, remove ' the last line of code (SwapBytes = b , ' and take advantage of the fact the ' original byte array is being passed ' to the function ByRef, therefore any ' changes made to the passed data are ' actually being made to the original data. ' With this workaround the calling code ' also requires modification: ' ' di. Model = StrConv(SwapBytes , vbUnicode) ' ' ... to... ' ' Call SwapBytes ' di. Model = StrConv Dim bTemp As Byte Dim cnt As Long For cnt = LBound To UBound Step 2 bTemp = b b = b(cnt + 1) b(cnt + 1) = bTemp Next cnt SwapBytes = b End Function Mac Adress: command button (command1) ve text box (text1) ekleyiniz Kod: Option Explicit '''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''' ' Copyright ©1996-2009 VBnet, Randy Birch, All Rights Reserved. ' Some pages may also contain other copyrights by the author. '''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''' ' Distribution: You can freely use this code in your own ' applications, but you may not reproduce ' or publish this code on any web site, ' online service, or distribute as source ' on any media without express permission. '''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''' Private Const NCBASTAT As Long = &H33 Private Const NCBNAMSZ As Long = 16 Private Const HEAP_ZERO_MEMORY As Long = &H8 Private Const HEAP_GENERATE_EXCEPTIONS As Long = &H4 Private Const NCBRESET As Long = &H32 Private Type NET_CONTROL_BLOCK 'NCB ncb_command As Byte ncb_retcode As Byte ncb_lsn As Byte ncb_num As Byte ncb_buffer As Long ncb_length As Integer ncb_callname As String NCBNAMSZ ncb_name As String NCBNAMSZ ncb_rto As Byte ncb_sto As Byte ncb_post As Long ncb_lana_num As Byte ncb_cmd_cplt As Byte ncb_reserve(9) As Byte 'Reserved, must be 0 ncb_event As Long End Type Private Type ADAPTER_STATUS adapter_address(5) As Byte rev_major As Byte reserved0 As Byte adapter_type As Byte rev_minor As Byte duration As Integer frmr_recv As Integer frmr_xmit As Integer iframe_recv_err As Integer xmit_aborts As Integer xmit_success As Long recv_success As Long iframe_xmit_err As Integer recv_buff_unavail As Integer t1_timeouts As Integer ti_timeouts As Integer Reserved1 As Long free_ncbs As Integer max_cfg_ncbs As Integer max_ncbs As Integer xmit_buf_unavail As Integer max_dgram_size As Integer pending_sess As Integer max_cfg_sess As Integer max_sess As Integer max_sess_pkt_size As Integer name_count As Integer End Type Private Type NAME_BUFFER name As String NCBNAMSZ name_num As Integer name_flags As Integer End Type Private Type ASTAT adapt As ADAPTER_STATUS NameBuff(30) As NAME_BUFFER End Type Private Declare Function Netbios Lib "netapi32" _ As Byte Private Declare Sub CopyMemory Lib "kernel32" _ Alias "RtlMoveMemory" _ Private Declare Function GetProcessHeap Lib "kernel32" As Long Private Declare Function HeapAlloc Lib "kernel32" _ As Long Private Declare Function HeapFree Lib "kernel32" _ As Long Private Sub Command1_Click 'in calling, pass the character you 'want as a delimiter between MAC 'address members Text1. Text = GetMACAddress End Sub Private Function GetMACAddress As String 'retrieve the MAC Address for the network controller 'installed, returning a formatted string Dim tmp As String Dim pASTAT As Long Dim NCB As NET_CONTROL_BLOCK Dim AST As ASTAT Dim cnt As Long 'The IBM NetBIOS 3.0 specifications defines four basic 'NetBIOS environments under the NCBRESET command. Win32 'follows the OS/2 Dynamic Link Routine environment. 'This means that the first NCB issued by an application 'must be a NCBRESET, with the exception of NCBENUM. 'The Windows NT implementation differs from the IBM 'NetBIOS 3.0 specifications in the NCB_CALLNAME field. NCB. ncb_command = NCBRESET Call Netbios 'To get the Media Access Control address for an 'ethernet adapter programmatically, use the Netbios 'NCBASTAT command and provide a " " as the name in the 'NCB. ncb_CallName field (in a 16-chr string). NCB. ncb_callname = " " NCB. ncb_command = NCBASTAT 'For machines with multiple network adapters you need to 'enumerate the LANA numbers and perform the NCBASTAT 'command on each. Even when you have a single network 'adapter, it is a good idea to enumerate valid LANA numbers 'first and perform the NCBASTAT on one of the valid LANA 'numbers. It is considered bad programming to hardcode the 'LANA number to 0 . NCB. ncb_lana_num = 0 NCB. ncb_length = Len pASTAT = HeapAlloc(GetProcessHeap , _ HEAP_GENERATE_EXCEPTIONS Or _ HEAP_ZERO_MEMORY, _ NCB. ncb_length) If pASTAT <> 0 Then NCB. ncb_buffer = pASTAT Call Netbios CopyMemory AST, NCB. ncb_buffer, Len 'convert the byte array to a string GetMACAddress = MakeMacAddress(AST. adapt. adapter_address , sDelimiter) HeapFree GetProcessHeap , 0, pASTAT Else Debug. Print "memory al failed!" Exit Function End If End Function Private Function MakeMacAddress(b As Byte, sDelim As String) As String Dim cnt As Long Dim buff As String On Local Error GoTo MakeMac_error 'so far, MAC addresses are 'exactly 6 segments in size (0-5) If UBound = 5 Then 'concatenate the first five values 'together and separate with the 'delimiter char For cnt = 0 To 4 buff = buff & Right$("00" & Hex(b , 2) & sDelim Next 'and append the last value buff = buff & Right$("00" & Hex(b(5)), 2) End If 'UBound MakeMacAddress = buff MakeMac_exit: Exit Function MakeMac_error: MakeMacAddress = " " Resume MakeMac_exit End Function

okadar kişi bakıyor ama cvp veren yok yokmu forumda şunun kodlarını verebilecek ya mantık şu zaten, yaptığım programı sadece o pc de çalıştırabilecek user.. arkına msn den atsa bile HDD serial no kayıtlı olduğu için çalişmicak sadece bunu istiyorum.