DISQUS

DISQUS Hello!  The comments on this profile are unclaimed and thus are unverified.

Do they belong to you? Claim these comments.

Paul's picture

Unregistered

Feeds

aliases

  • Paul

Paul

11 months ago

in WGet 2 for PowerShell on Huddled Masses
I couldn't get it to work specifying a path for the file (and the filename) - I kept getting 'access denied' or the path would be appended to the user home directory.

I changed:

if($fileName -and !(Split-Path $fileName))

to:

if($fileName -ne $null -and (Split-Path $fileName) -ne $null)

which worked. I prefer specifying things in this way as I believe they are also easier to read.

Comments in the script would also have been nice for this of us newer to PS than others!
Returning? Login