Hi everyone -
I'm stuck with New-Item cmdlet creating a file instead of directory even though I specifically add -ItemType "directory"
Here's my code (inside of a -Scriptblock):
New-Item -Path "c:\" -Name "RXtemp" -ItemType "directory"
However when done using Invoke-Command, it works.
Invoke-Command -computername Target -scriptblock {New-Item -Path "c:\" -Name "RXtemp" -ItemType "directory"}
Am I missing something here?

