Solve IntelliSense hangs in Integrated Scripting Environment

Solve an annoying intellisense hang with the ISE.

John Savill

February 27, 2016

1 Min Read
Solve IntelliSense hangs in Integrated Scripting Environment

Q. I am using the PowerShell Integrated Scripting Environment (ISE) however every command I type results in a 30 second delay that Intellisense is stopping. How do I fix this?

A. I recently saw this on a box that an add-in had recently been removed from. Every time I typed at the bottom of the screen it would have a message that Intellisense was stopping but it would hang for about 30 seconds and during this time I could not run PowerShell within the environment. The problem was the cache PowerShell ISE uses to remember all the commands in each module and it will still trying to access modules that were not present and the timeout was caused by trying to find the content. The solution was to remove the cache:

  1. Stop the PowerShell ISE

  2. Navigate to $env:LOCALAPPDATAMicrosoftWindowsPowerShellCommandAnalysis, for example C:UsersjohnAppDataLocalMicrosoftWindowsPowerShellCommandAnalysis

  3. Delete all the files

  4. Restart PowerShell ISE

Note it will take some times to recache the available commands for Intellisense to function but the previous hang should be fixed.

About the Author

Sign up for the ITPro Today newsletter
Stay on top of the IT universe with commentary, news analysis, how-to's, and tips delivered to your inbox daily.

You May Also Like