Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. Visual Basic
  4. Real HDD serial number

Real HDD serial number

Scheduled Pinned Locked Moved Visual Basic
tutorialquestion
5 Posts 2 Posters 1 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • X Offline
    X Offline
    Xanty
    wrote on last edited by
    #1

    Hi! I'm trying to find a way of retrieving the serial number of all the hard drives in a PC, not the Volume information, but the real hard drive, manufacturer serial number! I know i must use a virtual device driver file, but i don0y actually know how to do it! Where can i find a sample code, or just a good article on this subject? Thank you for your time

    J 1 Reply Last reply
    0
    • X Xanty

      Hi! I'm trying to find a way of retrieving the serial number of all the hard drives in a PC, not the Volume information, but the real hard drive, manufacturer serial number! I know i must use a virtual device driver file, but i don0y actually know how to do it! Where can i find a sample code, or just a good article on this subject? Thank you for your time

      J Offline
      J Offline
      Jerome Conus
      wrote on last edited by
      #2

      Are you using VB6 or VB.NET ? For VB6, I would do this : In the Menu Project->References : Select 'Microsoft Scripting Runtime' Then in your code :Dim fso As FileSystemObject Set fso = New FileSystemObject MsgBox fso.Drives("c").SerialNumber Set fso = Nothing
      I'm not sure if this is exactly what you need. Jerome

      X 1 Reply Last reply
      0
      • J Jerome Conus

        Are you using VB6 or VB.NET ? For VB6, I would do this : In the Menu Project->References : Select 'Microsoft Scripting Runtime' Then in your code :Dim fso As FileSystemObject Set fso = New FileSystemObject MsgBox fso.Drives("c").SerialNumber Set fso = Nothing
        I'm not sure if this is exactly what you need. Jerome

        X Offline
        X Offline
        Xanty
        wrote on last edited by
        #3

        Thank you Jerome I'm using VB6, i did as you told me, and i got a number, like : 134763457, maybe this number is related to the partition serial number, because, once i have 2 partitions in this hard drive, for "e" i got another number. What i needed is the vendors serial number that can be read on the hard drive. Do you know a way to do this? Thank you once more

        J 1 Reply Last reply
        0
        • X Xanty

          Thank you Jerome I'm using VB6, i did as you told me, and i got a number, like : 134763457, maybe this number is related to the partition serial number, because, once i have 2 partitions in this hard drive, for "e" i got another number. What i needed is the vendors serial number that can be read on the hard drive. Do you know a way to do this? Thank you once more

          J Offline
          J Offline
          Jerome Conus
          wrote on last edited by
          #4

          I understand now exactly what you want. You're right, the number you get is the Serial number of the volume. I'm afraid I won't be able to help you on how to get the manufacturer serial number, I've got no idea how to get it... Sorry, Jerome

          X 1 Reply Last reply
          0
          • J Jerome Conus

            I understand now exactly what you want. You're right, the number you get is the Serial number of the volume. I'm afraid I won't be able to help you on how to get the manufacturer serial number, I've got no idea how to get it... Sorry, Jerome

            X Offline
            X Offline
            Xanty
            wrote on last edited by
            #5

            Thank ok, thank you the same :)

            1 Reply Last reply
            0
            Reply
            • Reply as topic
            Log in to reply
            • Oldest to Newest
            • Newest to Oldest
            • Most Votes


            • Login

            • Don't have an account? Register

            • Login or register to search.
            • First post
              Last post
            0
            • Categories
            • Recent
            • Tags
            • Popular
            • World
            • Users
            • Groups