I’ve been trying to write this script that has a path to a .dll with a space in it. Every example I came upon either used single quotes, double quotes or nothing at all.

I tried

Import-Module -name 'c:\program files\EqualLogic\bin\EqlPSTools.dll'


Import-Module -name "c:\program files\EqualLogic\bin\EqlPSTools.dll"

There are 2 ways that worked:

Import-Module -name c:\program` files\EqualLogic\bin\EqlPSTools.dll

Using the back tick character, below the tilde on a Windows keyboard. Not to be confused with the opening single quote.



Import-Module -name ("c:\program files\EqualLogic\bin\EqlPSTools.dll")

For more on commonly confused characters, check out this page.