"4" Write-Host "`n📁 Startup Folder:" -ForegroundColor Cyan Get-ChildItem ([Environment]::GetFolderPath("Startup"))
"3" Select-Object Name Write-Host "--- Registry Run Items ---" -ForegroundColor Yellow Get-ItemProperty "HKCU:\Software\Microsoft\Windows\CurrentVersion\Run" add app to start up windows 11
switch ($choice) "1" $appPath = Pick-AppPath if (-not $appPath) Write-Host "No file selected." -ForegroundColor Red; exit Add app via Registry (hidden startup)" Write-Host "3
$startupFolder = [Environment]::GetFolderPath("Startup") $shortcutPath = Join-Path $startupFolder "$([System.IO.Path]::GetFileNameWithoutExtension($appPath)).lnk" $WScriptShell = New-Object -ComObject WScript.Shell $shortcut = $WScriptShell.CreateShortcut($shortcutPath) $shortcut.TargetPath = $appPath $shortcut.WorkingDirectory = [System.IO.Path]::GetDirectoryName($appPath) $shortcut.Save() Write-Host "✅ Added to startup (visible in Task Manager > Startup apps)" -ForegroundColor Green Startup apps)" -ForegroundColor Green <
<# .SYNOPSIS Add any application to Windows 11 Startup (Current User or All Users) .DESCRIPTION Creates a startup shortcut in the appropriate Startup folder or adds a registry entry for silent background apps. #> function Pick-AppPath Out-Null return $openFileDialog.FileName Main menu Write-Host "========================================" -ForegroundColor Cyan Write-Host " Add App to Windows 11 Startup" -ForegroundColor White Write-Host "========================================" -ForegroundColor Cyan Write-Host "1. Add app via Startup Folder (visible in Task Manager)" Write-Host "2. Add app via Registry (hidden startup)" Write-Host "3. Remove an app from startup" Write-Host "4. List current startup apps" Write-Host "========================================"
"2" $appPath = Pick-AppPath if (-not $appPath) Write-Host "No file selected." -ForegroundColor Red; exit $regPath = "HKCU:\Software\Microsoft\Windows\CurrentVersion\Run" $name = Read-Host "Enter a name for this startup entry (e.g., MyApp)" Set-ItemProperty -Path $regPath -Name $name -Value "`"$appPath`"" Write-Host "✅ Added to Registry (hidden startup – not in Task Manager startup list)" -ForegroundColor Green
$choice = Read-Host "Choose option (1-4)"