Service Tag

Posted on 2006-04-19
Last Modified: 2012-06-27
I'm looking to get a remote computer Service Tag displayed on my desktop computer. I know the Ip address of all the
remote computers and I have all admin rights. Is there any sort of VB program that will do the job for me ? They are all
Dell Optiplex. That's is pretty handy when it comes to log service calls.

please help !!
Question by:Bianchi928
    LVL 6

    Expert Comment

    a good tool is scriptomatic, that shows you lots of WMI commands, such as the one you are looking for

    Save this as a .vbs file and run
    Replace the . in arrComputers = Array(".") with the machine name


    On Error Resume Next

    Const wbemFlagReturnImmediately = &h10
    Const wbemFlagForwardOnly = &h20

    arrComputers = Array(".")
    For Each strComputer In arrComputers
       WScript.Echo "Computer: " & strComputer

       Set objWMIService = GetObject("winmgmts:\\" & strComputer & "\root\CIMV2")
       Set colItems = objWMIService.ExecQuery("SELECT * FROM Win32_ComputerSystemProduct", "WQL", _
                                              wbemFlagReturnImmediately + wbemFlagForwardOnly)

       For Each objItem In colItems
          WScript.Echo "IdentifyingNumber: " & objItem.IdentifyingNumber
          WScript.Echo "Name: " & objItem.Name
          WScript.Echo "UUID: " & objItem.UUID
          WScript.Echo "Vendor: " & objItem.Vendor


    Author Comment

    This works fine as long as it's the local computer (my computer) . But what I need is to be able to get the same infos from a remote computer. When I replace the "." with remote computer name , it only displays the computer and terminates (that's the first Wscript Echo)
    LVL 6

    Expert Comment

    it means it cannot find the machine for some reason

    instead of the dot or hostname try ip address

    or try fully qualified domain name


    it works here, try a different computer????? just to test that it works
    LVL 12

    Expert Comment

    not sure if you can do it, but we have the tag in the computername and use a program called whoami (

    whoami puts the name of the pc and IP in the upperright corner of the screen... its also configureable to add other things... like desktop, name of user logon.. etc

    whoamI is run as a logon script- but can be put in the all users startup profile...

    LVL 23

    Accepted Solution

    Dell Service Tag script:

    ============ copy everything below this line ==============
    on error resume next
    Set objWMIservice = GetObject("winmgmts:\\" & strComputer & "\root\cimv2")
    set colitems = objWMIservice.ExecQuery("Select * from Win32_BIOS",,48)
    For each objitem in colitems
          Wscript.echo "Dell Service Tag: " & objitem.serialnumber
    ============= and stop just above this line ===============

    then paste it into notepad, and save it as a *.vbs file - say delltag.vbs

    run with
    cscript delltag.vbs <PCname>


    note the info there about running across different domains.  

    Author Comment


    That works fine as long as the remote Computer is on the same Domain as where I'm running the cscript . What about if the remote computer is on a different Domain.


    LVL 6

    Expert Comment

    1st did you try and use the full domain name in host?

    ohhh thats proly why mine didnt work, because your PC is on a different domain.....

    ok use dameware
    demo avaliable

    1st copy the vbs file to that machine

    open dameware
    then on the right pane select domain
    then computer
    then remote command
    then Rcmd View

    and type the command there

    Featured Post

    Better Security Awareness With Threat Intelligence

    See how one of the leading financial services organizations uses Recorded Future as part of a holistic threat intelligence program to promote security awareness and proactively and efficiently identify threats.

    Join & Write a Comment

    Most of the time we are in fix when all of sudden our systems behave weirdly.  Such problems cost time and effort... so it's best to take some preventive actions so that we can avoid such issues or overcome such problems more easily. Preventive M…
    If you build your web application in Visual Studio you'll get at least a few binaries, or .DLL, files in your bin folder. However, there is more compiling to be done. Normally this would happen when an ASP.NET resource within the web site is request…
    In this tutorial you'll learn about bandwidth monitoring with flows and packet sniffing with our network monitoring solution PRTG Network Monitor ( If you're interested in additional methods for monitoring bandwidt…
    Polish reports in Access so they look terrific. Take yourself to another level. Equations, Back Color, Alternate Back Color. Write easy VBA Code. Tighten space to use less pages. Launch report from a menu, considering criteria only when it is filled…

    754 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    20 Experts available now in Live!

    Get 1:1 Help Now