Page 1 of 1 1
Topic Options
#158301 - 2006-03-03 09:55 PM Get DELL Service Tag on Login
bajaluna Offline
Lurker

Registered: 2006-03-03
Posts: 1
Is there any way to get the Dell Service Tag Number on Login? I use Desktop Authority and would like to get the Dell Service Tag number and store in a database.
Top
#158302 - 2006-03-03 10:00 PM Re: Get DELL Service Tag on Login
Radimus Moderator Offline
Moderator
*****

Registered: 2000-01-06
Posts: 5187
Loc: Tampa, FL
Scriptlogic has a function that is based off of WMIQuery()... I think it is slWmiQuery()

$SerNo = WMIQuery("SerialNumber","Win32_BIOS")[0]
or
$SerNo = WMIQuery("SerialNumber","Win32_SystemEnclosure")[0]

Check with SL for the exact syntax of their version of the command
http://www.scriptlogic.com/support/apilibrary/Default.aspx?KeywordID=65

$SerNo = SLWMIQuery("SerialNumber","Win32_BIOS")


Edited by Radimus (2006-03-03 10:05 PM)
_________________________
How to ask questions the smart way <-----------> Before you ask

Top
#158303 - 2006-03-03 10:02 PM Re: Get DELL Service Tag on Login
NTDOC Administrator Offline
Administrator
*****

Registered: 2000-07-28
Posts: 11625
Loc: CA
Hello and welcome to the board.

Well here is some quick and dirty code that can do it.

The main idea was from Radimus and pops up a box with the Computer MODEL and SERIAL number and offers to launch the browser to go to the DELL support site.

You can easily modfiy to get or do what you want.

Break On
Dim $SO
$SO=SetOption('Explicit','On')
$SO=SetOption('NoVarsInStrings','On')
$SO=SetOption('NoMacrosInStrings','On')

Dim $MyBIOSInfo,$Q
Global $Make,$Model,$SerNumb,$HKLMSMWCVAP,$Explorer,$Msg
$HKLMSMWCVAP = 'HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\App Paths'
$Explorer = ReadValue($HKLMSMWCVAP + '\IEXPLORE.EXE','')
$MyBIOSInfo=GetBIOSInfo()
$Make = $MyBIOSInfo[0]
$Model = $MyBIOSInfo[1]
$SerNumb = $MyBIOSInfo[2]

$Msg=MessageBox('MFG : ' + $Make +@CRLF + 'Model: ' + $Model + @CRLF + 'Serial : ' + $SerNumb + @CRLF+@CRLF+
'Go to the Web Support site for drivers ? ','Computer Model',4385)
If 1=$Msg
GoToMake()
EndIf
Exit 1

Function GetBIOSInfo()
Dim $WMIService, $Mfg,$Model,$Ser
Dim $MItem,$SItem, $SerialNumber, $Manufacturer
$WMIService = GetObject("winmgmts:" + "\root\cimv2")
$Mfg = $WMIService.ExecQuery("Select * from Win32_ComputerSystem",,48)
$Ser = $WMIService.ExecQuery("Select * from Win32_BIOS",,48)
For Each $MItem In $Mfg
If $MItem
$Manufacturer = Trim($MItem.Manufacturer)
$Model = Trim($MItem.Model)
EndIf
Next
For Each $SItem In $Ser
If $SItem
$SerialNumber = Trim($SItem.SerialNumber)
EndIf
Next
$GetBIOSInfo=$Manufacturer,$Model,$SerialNumber
EndFunction

Function GoToMake()
Dim $URL
Select
Case InStr($Make,'dell') $URL = "http://support.dell.com/support/downloads/index.aspx?ServiceTag="+$SerNumb
Case 1 $URL = ''
EndSelect
If $URL
RUN $Explorer + ' ' + $URL
Else
$Msg=MessageBox('Unable to determine computer model.','Model unknown',48)
EndIf
EndFunction

Top
#158304 - 2006-03-04 01:31 AM Re: Get DELL Service Tag on Login
Allen Administrator Offline
KiX Supporter
*****

Registered: 2003-04-19
Posts: 4560
Loc: USA
...and if you want to convert the Dell Service Tag to the Express Service Code just use the BaseConverter UDF.

Code:

$ESC=BaseConverter("5RFDP01",36,10)
? $ESC


Top
#158305 - 2006-03-04 01:49 AM Re: Get DELL Service Tag on Login
NTDOC Administrator Offline
Administrator
*****

Registered: 2000-07-28
Posts: 11625
Loc: CA
What are the Dell™ Express Service Code and Service Tag, and where can I find them?

Dell Service Tag or Express Service Code
http://www.dell.com/support/contents/us/...ate-service-tag

The Service Tag is a 7-character code, and the Express Service Code is a 10 to 11-digit code that is a numeric version of the Service Tag. Dell uses these product identifiers to access information about your device’s specific tech specs and warranty so that we can provide personalized support options.


Servers and storage products

How to find the service tag on a Dell server or storage system.

The Dell service tag is a seven character identifier that is unique to your product. In addition to the service tag, there is an Express Service Code which is a 10-digit numeric version of the service tag which can be typed into a telephone for call routing. While most Dell products have a service tag, some accessories and peripherals do not. As a general rule, desktop and notebook computers, servers and storage devices, printers, and mobile devices (such as phones or tablets) will have a service tag.



Edited by NTDOC (2018-01-17 12:53 AM)
Edit Reason: Updated URL and info

Top
#158306 - 2006-03-04 02:03 AM Re: Get DELL Service Tag on Login
Allen Administrator Offline
KiX Supporter
*****

Registered: 2003-04-19
Posts: 4560
Loc: USA
Quote:

What are the Dell™ Express Service Code and Service Tag, and where can I find them?





uhh... Doc? Come on now... Surly you know where those are found without having to look it up on their website

Top
#158307 - 2006-03-04 02:11 AM Re: Get DELL Service Tag on Login
NTDOC Administrator Offline
Administrator
*****

Registered: 2000-07-28
Posts: 11625
Loc: CA
ROFL - Actually I didn't know what the Express Service Code was for as I never needed or used it.

But with no further ado... Here is a more complete solution for this subject.

Thanks for the idea and UDF code Allen / Jooel.

Break On
Dim $SO
$SO=SetOption('Explicit','On')
$SO=SetOption('NoVarsInStrings','On')
$SO=SetOption('NoMacrosInStrings','On')

Dim $Chk, $MyBIOSInfo
Dim $Mfg, $Model, $Ser, $Esc
$Chk = WMIConfirm('computer name')
If $Chk
$MyBIOSInfo = GetBIOSInfo()
If VarType($MyBIOSInfo) >8
$Mfg = $MyBIOSInfo[0]
'Mfg: ' + $Mfg ?
$Model = $MyBIOSInfo[1]
'Model: ' + $Model ?
$Ser = $MyBIOSInfo[2]
'Serial / Tag number: ' + $Ser ?
$Esc = BaseConverter($Ser,36,10)
'Express Service Code: ' + $Esc ?
Else
'Error getting BIOS information. ' + @ERROR + ' - ' + @SERROR ?
EndIf
Else
'Error accessing WMI. ' + @ERROR + ' - ' + @SERROR ?
EndIf

Function WMIConfirm(optional $sComputer)
Dim $objWMIService, $objWMISetting, $colWMISettings
$sComputer = IIf(Not $sComputer,'','\\'+Join(Split($sComputer,'\'),'',3)+'\')
$objWMIService = GetObject("winmgmts:{impersonationLevel=impersonate}!"+$sComputer+'root\cimv2')
; Failed - return 0 and exit with error value
If @ERROR
$WMIConfirm = 0
Exit Val('&' + Right(DecToHex(@ERROR), 4))
EndIf
$colWMISettings = $objWMIService.ExecQuery("Select * from Win32_WMISetting")
For Each $objWMISetting In $colWMISettings
$WMIConfirm = $objWMISetting.BuildVersion
Next
Exit 0
EndFunction

Function GetBIOSInfo(optional $sComputer)
Dim $objWMIService, $Mfg,$Model,$Ser
Dim $M,$S, $SerialNumber, $Manufacturer
$objWMIService = GetObject("winmgmts:{impersonationLevel=impersonate}!"+$sComputer+'root\cimv2')
If @ERROR
$GetBIOSInfo = 0
Exit Val('&' + Right(DecToHex(@ERROR), 4))
EndIf
$Mfg = $objWMIService.ExecQuery("Select * from Win32_ComputerSystem",,48)
$Ser = $objWMIService.ExecQuery("Select * from Win32_BIOS",,48)
For Each $M In $Mfg
If $M
$Manufacturer = Trim($M.Manufacturer)
$Model = Trim($M.Model)
EndIf
Next
For Each $S In $Ser
If $S
$SerialNumber = Trim($S.SerialNumber)
EndIf
Next
$GetBIOSInfo=$Manufacturer,$Model,$SerialNumber
Exit 0
EndFunction

Function BaseConverter($v,$f,$t)
dim $,$e,$y,$n,$x,$z
$=0
$t=$+$t
$f=$+$f
$e=($f>36)|($t>36)|($f<2)|($t<2)
$y=1.
for $n=len($v) to 1 step -1
$x=ASC(UCASE(substr($v,$n,1)))
$z=($x-48-($x>64)*7)
IF ($z<0)|(($x>57)&($x<65))|$e|($z>($f-1))
EXIT 1
ENDIF
$=$y*$z+$
$y=$y*$f
next
$n=""
While $
$x=INT($-(INT($/$t)*$t))
$=($-$x)/$t
$n=CHR($x+48+($x>9)*7)+$n
Loop
$BaseConverter=$n
Endfunction

Top
Page 1 of 1 1


Moderator:  Jochen, Allen, Radimus, Glenn Barnas, ShaneEP, Ruud van Velsen, Arend_, Mart 
Hop to:
Shout Box

Who's Online
0 registered and 626 anonymous users online.
Newest Members
min_seow, Audio, Hoschi, Comet, rrosell
17881 Registered Users

Generated in 0.063 seconds in which 0.023 seconds were spent on a total of 12 queries. Zlib compression enabled.

Search the board with:
superb Board Search
or try with google:
Google
Web kixtart.org