# Can powershell do this?

**URL:** https://forums.powershell.org/t/can-powershell-do-this/255
**Category:** PowerShell Help
**Created:** [December 31, 2011, 6:30pm UTC](https://forums.powershell.org/t/can-powershell-do-this/255 "2011-12-31T18:30:00Z")
**Posts on this page:** 2
**Page:** 1

<div class="post-metadata">

### Author: ![archives](https://avatars.discourse-cdn.com/v4/letter/a/bb73d2/32.png) [@archives](https://forums.powershell.org/u/archives)
#### Post date: [December 31, 2011, 6:30pm UTC](https://forums.powershell.org/t/can-powershell-do-this/255/1 "2011-12-31T18:30:00Z")

</div>

by eyewon at 2012-10-16 10:19:04

> We need to change our mac environment to a Windows server and I need to know if I can do the following tasks automatically with Powershell.  
>   
> #1 - Check on an external ftp site to see if a file is available  
> #2 - When the file is available, I need to download it and relocate it on the same server  
> #3 - I need to open a share from another Windows server and copy the file to it  
> #4 - I need to wait for the file to be transformed on the share and get the new file when it is transformed (Different filename)  
> #5 - Copy to a OSX mac share (samba)  
> #5 - Rename the file and place it to another ftp location.  
>   
> Can this be all automated without user intervention?  
>   
> If you need more details on the step, I can provide them with no problem.  
>   
> Thank you for your help everyone.

by DonJ at 2012-10-17 08:29:12

> 1. Not natively. You’d need to script up an FTP check yourself, or use something like /n software’s NetCmdlets, which can talk to FTP.  
>   
> 2. See #1.  
>   
> 3. Sure.  
>   
> 4. I’m not sure what you mean by "transformed." If there’s some action being done to the file, you’d need some way to detect that. You could use a .NET Framework FileSystemWatcher to watch for a new file in that folder, I suppose, provided the file won’t show up until it’s done. If the file is created and then written to over a period of time, you’d likely have to keep checking it until it closes.  
>   
> 5. Sure. Same as a Windows share. Technically CIFS or SMB, not Samba.  
>   
> 5 again. Again, nothing native in PowerShell for FTP.  
>   
> I suspect you could do much of this in PowerShell by using the native ftp.exe, since ftp.exe actually accepts scripts. Check out its docs.

---

<div class="post-metadata">

### Author: ![dotnVo](https://avatars.discourse-cdn.com/v4/letter/d/4af34b/32.png) [@dotnVo](https://forums.powershell.org/u/dotnVo)
#### Post date: [May 16, 2024, 8:58pm UTC](https://forums.powershell.org/t/can-powershell-do-this/255/2 "2024-05-16T20:58:10Z")

</div>


