Warning: file_get_contents(/data/phpspider/zhask/data//catemap/2/powershell/13.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
如何使用powershell命令检索MHTML文件信息_Powershell - Fatal编程技术网

如何使用powershell命令检索MHTML文件信息

如何使用powershell命令检索MHTML文件信息,powershell,Powershell,我有一个mhtml文件test.mht test.mht中的数据如下所示 字段字符串 名称拼车 键入ModernApp 美国英语中的语言 分类工具 IsTrial false GUID 712ec8b1-0370-4ed5-b1ac-f0eca1f64348 市场 MarketName 美国 串 字段串 问题: 如何使用powershell命令检索GUID信息 例: $GetGUID=[加载mhtm文件] 写入主机$GetGUID.GUID 应打印:712ec8b1-0370-4ed5-b1ac

我有一个mhtml文件test.mht test.mht中的数据如下所示

字段字符串
名称拼车
键入ModernApp
美国英语中的语言
分类工具
IsTrial false
GUID 712ec8b1-0370-4ed5-b1ac-f0eca1f64348
市场 MarketName
美国
串 字段串

问题: 如何使用powershell命令检索GUID信息

例: $GetGUID=[加载mhtm文件] 写入主机$GetGUID.GUID
应打印:712ec8b1-0370-4ed5-b1ac-f0eca1f64348

(Get-Content .\Test.mht) -Match "^(?<=GUID\s+).+$" | Out-Null; Write-Host $matches[0];

(Get Content.\Test.mht)-Match“^(?$ID=@()[array]$ID=(Get Content C:\Test.mht)-Match”^(?(Get Content.\Test.mht)-Match“^(?因为对唯一提供的答案没有响应,所以被否决。