Many thanks NetWallah for the great update! Your use of the correct term for the hex servicename (GUID), jogged my memory on when I last looked into this stuff. I may be able to dig up something from the past.

Here is the problem I asking for direction with now:

On my machine, "wmic nic list brief" gives me 22 devices:

AdapterType DeviceID MACAddress Name Ethernet 802.3 1 xx:xx:xx:xx:xx:xx Intel(R) PRO/1000 PL Ne Ethernet 802.3 2 xx:xx:xx:xx:xx:xx Intel(R) PRO/Wireless 3 3 Infrared Port Ethernet 802.3 4 xx:xx:xx:xx:xx:xx Packet Scheduler Minipo 6 Bluetooth Device (Perso 7 RAS Async Adapter 8 WAN Miniport (L2TP) Wide Area Network 9 xx:xx:xx:xx:xx:xx WAN Miniport (PPTP) Wide Area Network 10 xx:xx:xx:xx:xx:xx WAN Miniport (PPPOE) 11 Direct Parallel 12 WAN Miniport (IP) Ethernet 802.3 13 xx:xx:xx:xx:xx:xx Packet Scheduler Minipo Ethernet 802.3 14 xx:xx:xx:xx:xx:xx Packet Scheduler Minipo Ethernet 802.3 15 xx:xx:xx:xx:xx:xx Lucent VPN Miniport Ethernet 802.3 16 xx:xx:xx:xx:xx:xx Lucent VPN Miniport Ethernet 802.3 17 xx:xx:xx:xx:xx:xx Lucent VPN Miniport 18 WAN Miniport (Network Ethernet 802.3 19 xx:xx:xx:xx:xx:xx Packet Scheduler Minipo 20 Linksys Etherfast USB 21 Packet Scheduler Minipo 22 Lucent VPN Miniport
However, looking at the registry with the following code, I only get information on 3 of the devices:
use strict; use Win32::TieRegistry; use Data::Dumper; my $dev="LMachine/SOFTWARE/Microsoft/Windows NT/CurrentVersion/Network +Cards/"; my $key= $Registry->Open($dev, { Access => "KEY_READ", Delimiter => "/ +" } ); print Dumper($key); $VAR1 = bless( { '2/' => bless( { '/ServiceName' => '{8BAA28BF-8565-43BE-81C0-E7BBD94187D3}', '/Description' => 'Intel(R) PRO/1000 PL Network Connection' }, 'Win32::TieRegistry' ), '21/' => bless( { '/ServiceName' => '{15B70374-1CD7-416E-A08A-22F96A502A54}', '/Description' => 'Linksys Etherfast USB 10/100 Ethernet Adapter' }, 'Win32::TieRegistry' ), '3/' => bless( { '/ServiceName' => '{7F8B1DE7-B0AA-40C0-8D89-D0325F269899}', '/Description' => 'Intel(R) PRO/Wireless 3945ABG Network Connectn' }, 'Win32::TieRegistry' ) }, 'Win32::TieRegistry' );
I would like to get the GUID for a device that doesn't appear in the registry. How do I do this?

Anticipating a possible answer: If the GUID doesn't exist, how can I get one created for a given device?

Many, many, thanks!

-Craig


In reply to Re^3: WindowsRegistry{ServiceName} V.S. wmic{ServiceName} by cmv
in thread WindowsRegistry{ServiceName} V.S. wmic{ServiceName} UPDATE: Solved by cmv

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.