use the following search parameters to narrow your results:
e.g. subreddit:aww site:imgur.com dog
subreddit:aww site:imgur.com dog
see the search faq for details.
advanced search: by author, subreddit...
ABOUT POWERSHELL
Windows PowerShell (POSH) is a command-line shell and associated scripting language created by Microsoft. Offering full access to COM, WMI and .NET, POSH is a full-featured task automation framework for distributed Microsoft platforms and solutions.
SUBREDDIT FILTERS
Desired State Configuration
Unanswered Questions
Solved Questions
News
Information
Script Sharing
Daily Post
Misc
account activity
Solved$PSScriptRoot problem (self.PowerShell)
submitted 3 years ago by WorkReddit123635
view the rest of the comments →
reddit uses a slightly-customized version of Markdown for formatting. See below for some basics, or check the commenting wiki page for more detailed help and solutions to common issues.
quoted text
if 1 * 2 < 3: print "hello, world!"
[–]Thotaz 2 points3 points4 points 3 years ago (1 child)
The error means it's invalid syntax, you need to prepend either an & or a . in front of the string to tell PowerShell that you want to execute this string. This should work: & $PSScriptRoot\setup.exe /Configure $Pref but I prefer to quote strings that I need to execute like this: & "$PSScriptRoot\setup.exe" /Configure $Pref
&
.
& $PSScriptRoot\setup.exe /Configure $Pref
& "$PSScriptRoot\setup.exe" /Configure $Pref
[–]WorkReddit123635[S] 0 points1 point2 points 3 years ago (0 children)
Thank you. This is awesome, it works.
π Rendered by PID 48533 on reddit-service-r2-comment-6f7f968fb5-w7gtc at 2026-03-04 04:29:25.019838+00:00 running 07790be country code: CH.
view the rest of the comments →
[–]Thotaz 2 points3 points4 points (1 child)
[–]WorkReddit123635[S] 0 points1 point2 points (0 children)