How to get count of files copied using Copy-item This topic contains 2 replies, has 2 voices, and was last updated by Dinesh Kumar 4 weeks, 1 day ago. Author Posts June 19, 2018 at 4:21 pm #102805 Dinesh KumarParticipant Hi, I am using Copy-Item command to copy the multiple files from one location to another. In that, I want to get the count of files that are copied to destination. If the above one is not possible, can we get 'True' if at least one file is copied and 'False' if none of the files are copied. I tried this but could not able to get exact one. Thanks, Dinesh June 19, 2018 at 4:23 pm #102808 Don JonesKeymaster Sure. Many commands, including Copy-Item, have a -PassThru parameter, which causes them to output the object they just acted against. Copy-Item a b -PassThru | Measure-Object By outputting the acted-upon objects, you can pipe them to Measure-Object to count them. June 20, 2018 at 6:47 am #102815 Dinesh KumarParticipant Thanks for the response. Its working as expected. Author Posts You must be logged in to reply to this topic.