It was a regular Tuesday morning and I hadn’t yet had my ‘PowerShell fix’ for the week, so when I realised I needed to download a new driver pack from Dell for my ConfigMgr OS deployments, I could hear a faint voice calling out to me: ‘Dude, I can make your life easier! Work smarter, not harder!‘
Of course, that’s only ever partially true, because with PowerShell you must work harder today in order to work smarter tomorrow, but in the interest of long-term benefit I proceeded to fire up the ISE.
Suddenly, a thought arose from my subconscious: ‘Wait just a second. Don’t re-invent the wheel. Aren’t there already some good solutions out there for this?‘
‘Well yes, that’s true,‘ my internal musings continued. ‘Most notably, we have a very cool tool by Maurice Daly – the Driver Automation Tool. With this we can just click buttons and go get coffee while the tool does all the hard work. It’ll even import the driver packs into SCCM. I like that!‘
‘Yes that is awesome.‘ I responded to myself, ‘Problem is, I still need a PowerShell fix. So maybe I can find a different way of downloading driver packs. What do you suggest?‘
‘Well, we have the Dell Driver Pack Catalog. Dell even provide examples of how to use that with PowerShell to find the URLs you need to download the relevant cab files.‘
‘Yes, this is cool too. But I think there is still another way. Doesn’t Dell’s TechCenter wiki contain the download URLs for the most recent driver packs?‘
‘Yes, it does. But you want to use PowerShell, right?‘
‘Correct.’
‘So what are you thinking?‘
‘Web-scraping.‘
‘Ah, you bad boy! Let’s do it!‘
Dell maintains a wiki page containing links to the latest driver packs which can be found here:
You simply find the model and operating system version you want and click the link, which leads you to another wiki page containing a download URL.
Rolling up the sleeves, I whipped up some code that will scrape these web pages to find the download URL for the current driver pack version and download it using a BITS transfer. You can then import or add the driver pack into ConfigMgr for OSD using your favourite method (which is PowerShell, right?!)
The resulting script is quite simple to use and works reliably in my testing, although it takes a few seconds to filter the HTML in order to find the appropriate download URL.
You can download a driver pack for a single model, for example:
Download-LatestDellDriverPack -Model "Latitude E7470" -OperatingSystem 'Windows 10' -DownloadDirectory C:\DriverPacks -Verbose
Just provide the model name, operating system version and a location to save the downloaded file to. Support is provided for verbose output.
You can also pass a list of models to the script and it will download each one in turn, for example:
"M4800","Optiplex 9020","E6420","E5250" | Download-LatestDellDriverPack -OperatingSystem 'Windows 7' -DownloadDirectory C:\DriverPacks -Verbose

The script will work for any driver pack with an operating system Windows 7 or higher (are you really deploying anything older than that?!), and there is no proxy support currently.
Here’s the full script:
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[CmdletBinding()] | |
Param | |
( | |
[Parameter(Mandatory=$true, | |
ValueFromPipelineByPropertyName=$true, | |
ValueFromPipeline=$true, | |
Position=0)] | |
[String[]]$Model, | |
[Parameter(Mandatory=$true, | |
Position=1)] | |
[ValidateSet("Windows 10","Windows 8.1","Windows 8","Windows 7")] | |
$OperatingSystem, | |
[Parameter(Mandatory=$true, | |
Position=2)] | |
[String]$DownloadDirectory | |
) | |
Begin | |
{ | |
function Get-LatestDellDriverPackURL { | |
[CmdletBinding()] | |
Param | |
( | |
[Parameter(Mandatory=$true, | |
ValueFromPipelineByPropertyName=$true, | |
Position=0)] | |
[String]$Model, | |
[Parameter(Mandatory=$true, | |
ValueFromPipelineByPropertyName=$true, | |
Position=1)] | |
[ValidateSet("Windows 10","Windows 8.1","Windows 8","Windows 7")] | |
$OperatingSystem | |
) | |
# Remove the "E" prefix character from Latitude models due to some dodgy Dell URLs… | |
If ($Model.ToCharArray()[0] -eq "E" -and $Model -notmatch "Embedded") | |
{ | |
$Model = $Model.Replace("E","") | |
} | |
# Find the specific wiki page for the model from the main wiki page | |
$URI = "http://en.community.dell.com/techcenter/enterprise-client/w/wiki/2065.dell-command-deploy-driver-packs-for-enterprise-client-os-deployment" | |
Try | |
{ | |
$HTML = Invoke-WebRequest –Uri $URI –ErrorAction Stop | |
If ($OperatingSystem -eq "Windows 8") | |
{ | |
# Filter out Windows 8.1 from the results if it's just Windows 8 | |
$Href = $HTML.AllElements | Where {$_.innerText -match ("$Model" + " W") -and $_.innerText -match $OperatingSystem -and $_.innerText -notmatch "8.1" -and $_.innerText -match "Driver" -and $_.tagName -eq "A"} | Select –ExpandProperty href | |
} | |
Else | |
{ | |
$Href = $HTML.AllElements | Where {$_.innerText -match ("$Model" + " W") -and $_.innerText -match $OperatingSystem -and $_.innerText -match "Driver" -and $_.tagName -eq "A"} | Select –ExpandProperty href | |
} | |
} | |
Catch | |
{ | |
$_ | |
Return | |
} | |
If (!$Href) | |
{ | |
Write-Error "No Wiki page found for $Model and $OperatingSystem." | |
Return | |
} | |
# Find the download URL from the model | |
$URI = "http://en.community.dell.com/$Href" | |
Try | |
{ | |
$HTML = Invoke-WebRequest –Uri $URI –ErrorAction Stop | |
$CabDownloadLink = $HTML.AllElements | Where {$_.innerHTML -match "Download Now" -and $_.tagName -eq "A"} | Select –ExpandProperty href | |
Return $CabDownloadLink | |
} | |
Catch | |
{ | |
$_ | |
Return | |
} | |
Write-Error "No download URL found for $Model." | |
} | |
# Start a timer | |
$Stopwatch = New-Object System.Diagnostics.Stopwatch | |
$Stopwatch.Start() | |
} | |
Process | |
{ | |
Foreach ($System in $Model) | |
{ | |
Write-Verbose "Finding the download URL for '$System' and '$OperatingSystem'" | |
Try | |
{ | |
# Get the download URL | |
$URL = Get-LatestDellDriverPackURL –Model $System –OperatingSystem $OperatingSystem –ErrorAction Stop | |
} | |
Catch | |
{ | |
$Stopwatch.Stop() | |
$_ | |
Return | |
} | |
Write-Verbose "Initiating download of URL '$URL' with BITS" | |
Try | |
{ | |
# Begin the download | |
Start-BitsTransfer –Source $URL –Destination $DownloadDirectory | |
} | |
Catch | |
{ | |
$Stopwatch.Stop() | |
$_ | |
Return | |
} | |
} | |
} | |
End | |
{ | |
$Stopwatch.Stop() | |
Write-Verbose "Completed in $($Stopwatch.Elapsed.Minutes) minutes and $($Stopwatch.Elapsed.Seconds) seconds" | |
} |
Just a small correction on this post, the driver tool is now longer just for Dell ;). Its just “Driver Automation Tool” now as it works for multiple vendors. Keep up the good work.
Thanks for the correction…post has been updated!
Made my Day reading this. Awesome work
Hi Trevor, is this script still working? Getting error No Wiki page found for Latitude E7470 and Windows 10 when I try your example or any other DELL model.