[英]copy partial file powershell
i am trying to copy a part of a source exe file to new dst file, i use the following commnads: 我正在尝试将源exe文件的一部分复制到新的dst文件,我使用以下命令:
$file = (Get-Content src.exe)[31..111] | Set-Content dst.exe
but on the output file i get extra newline symbols which cause an error when i try to run the file. 但是在输出文件上,我得到了额外的换行符号,当我尝试运行该文件时会导致错误。 how do i copy the internal part of the file without damaging it.
我如何在不损坏文件的情况下复制文件的内部部分。
i attached a jpg of the dif. 我附上了dif的jpg。 please help
请帮忙
$file = (Get-Content src.exe -encoding byte)[31..111] | Set-Content dst.exe -encoding byte
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.