- ·上一篇教育:怎么找到系统自带word
- ·下一篇教育:word表格分两页断开怎么居中
word文档怎么快速查询同名
1.批处理如何查找同名文件
@echo off
set "whatif=0" %此处填1立即执行复制,填0显示代码执行结果不做任何处理%
if "%whatif%"=="0" (set "whatif=-whatif")else set "whatif="
set "a=a" %文件夹1%
set "b=b" %文件夹2%
powershell "ForEach($i in '%a%','%b%'){Set-Variable -Name $i -Value (dir $i).BaseName;Get-ChildItem -File $i|Copy-Item -Destination{if((Get-Variable -Name $i).Value -eq $_.BaseName){'c'}} %WhatIf% -ErrorAction Ignore -Force}"
pause
评论内容只代表网友观点,与本站立场无关!
评论摘要(共 0 条,得分 0 分,平均 0 分)