Ich habe die folgende Skript Arbeit in Windows 10, aber nicht auf Windows Embdedded Standard:Powershell-Skript arbeitet in 10 Windows aber nicht unter Windows Embedded Standard
$LogTime = Get-Date -Format "MM-dd-yyyy_hh-mm-ss"
$Path1= "TEST\TESTLog_$(get-date -f yyyy-MM-dd).txt"
$AffPBS= Get-Process "LLCService.exe" | Select-Object ProcessorAffinity
$AffLC= Get-Process "LCService.exe" | Select-Object ProcessorAffinity
$AffinityLLCFinal = "LLC " + $AffPBS
$AffinityLCFinal = "LC " + $AffLC
$FinalOutput = $LogTime+" " +$AffinityLLCFinal +" " + $AffinityLCFinal
$FinalOutput | Out-File -Append $Path1
ich die Powershell_ISE als Administrator ausgeführt habe und auch Set-ExecutionPolicy RemoteSigned
gesetzt.
Die Ergebnisse Ich bin auf Windows immer 10:
10-09-2017_03-31-10 LLC @{ProcessorAffinity=63} LC @{ProcessorAffinity=63}
die Ergebnisse Ich bin immer auf Windows 7:
10-09-2017_11-23-26 LLC LC
Es scheint, wie die Get-Process
wird unter Windows arbeiten Eingebettete Standard. Gibt es einen anderen Weg, dies zu tun?
Warum haben Sie entschieden, dass es nicht funktioniert? Was gibt das? 'Get-Process" LLCService.exe "| Select-Objekt ProcessorAffinity'? Wenn das leer ist, was gibt das: 'Get-Process explorer | Prozessor wählenAffinität? –