Hi, I want to get files only having last_write_time equal to today. The command i am trying:
Get-ChildItem $source | where-object {$_.LastWriteTime -ge (Get-Date).adddays(-1)}
Problem is, it's bringing few files from yesterday as well.
Get-ChildItem $source | where-object {$_.LastWriteTime -ge (Get-Date).adddays(-1)}
Problem is, it's bringing few files from yesterday as well.