PS for moving files with the word ARCHIVE in there naming of a specific path, to a spec path?


hello,

i'm trying figure out how ps script have in order move files word archive in there naming of specific path, network path?

 

any ideas?  thx

hi,

try this:

  $sourcelocation = "p:\test" $destlocation =  "\\g1\test2" get-childitem $sourcelocation  *archive* | move-item -destination $destlocation   



Windows Server  >  Windows PowerShell



Comments

Popular posts from this blog

WIMMount (HSM) causing cluster storage to go redirected (2012r2 DC)

Failed to delete the test record dcdiag-test-record in zone test.com

Azure MFA with Azure AD and RDS