Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- # Bring a specific application to the foreground
- #
- # usage: Set-ForegroundWindow -ApplicationName "Internet Explorer"
- Function Set-ForegroundWindow
- {
- param ( [Parameter(Mandatory =$true, ValueFromPipelineByPropertyName=$true ,HelpMessage= "Name of the transaction", ValueFromPipeline=$true )] [string]$applicationname)
- add-type -AssemblyName microsoft.VisualBasic
- [Microsoft.VisualBasic.Interaction]::AppActivate($applicationname)
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement