Silent Install Visual Studio May 2026

$exitCode = Start-Process -Wait -PassThru vs_enterprise.exe -ArgumentList "--quiet --wait --norestart --add Microsoft.VisualStudio.Workload.NetWeb" if ($exitCode -eq 0) { Write-Host "Success!" } elseif ($exitCode -eq 3010) { Write-Host "Success, but reboot required." } else { Write-Host "Failed with code: $exitCode" }

vs_enterprise.exe --layout C:\VS2022_Layout \ --add Microsoft.VisualStudio.Workload.NativeDesktop \ --add Microsoft.VisualStudio.Workload.Universal \ --includeRecommended --lang en-US Then, from the target machine, run the silent install from the layout: silent install visual studio

vs_enterprise.exe --export config.vsconfig $exitCode = Start-Process -Wait -PassThru vs_enterprise

--nickname "DevOps Build Agent 2022" Here’s how you’d use this in a Windows container: from the target machine

Whether you’re maintaining a build farm, onboarding new developers, or just tired of clicking "Modify," the --quiet flag is your new best friend.

Open PowerShell or CMD and run:

For individual developers, clicking "Next" a few times is tolerable. But for DevOps pipelines, lab managers, or IT admins rolling out dozens of machines, the GUI is a bottleneck.