May 25th, 2010

Renaming Tabs in the ISE

PowerShell Team
PowerShell Team

When you have multiple PowerShell tabs open in the ISE, it may be handy to rename them, so you can tell which is which.  This is especially useful when using Remoting with Enter-PSSession.  The problem when using Enter-PSSession is that you have no access to the root ISE object ($psise) when remoting, so you should use another (local) tab and enter the following:

   $psise.PowerShellTabs[0].DisplayName = ‘myRemoteMachine’

Needless to say, if you want to rename the second tab, you’d use PowerShellTabs[1] … and so on

To rename the current PowerShell tab, enter:

   $psise.CurrentPowerShellTab.DisplayName = ‘PowerShellRocks’

ref@

Refaat Issa [MSFT]

Category
PowerShell

Author

PowerShell Team
PowerShell Team

PowerShell is a task-based command-line shell and scripting language built on .NET. PowerShell helps system administrators and power-users rapidly automate tasks that manage operating systems (Linux, macOS, and Windows) and processes.

0 comments

Discussion are closed.