diff --git a/Get-PC-Information.ps1 b/Get-PC-Information.ps1 index 355546f..0ef243b 100644 --- a/Get-PC-Information.ps1 +++ b/Get-PC-Information.ps1 @@ -145,10 +145,11 @@ function Display-Result { } function Output-To-File { - $file = "$HOME\AppData\Local\Temp\PC-Information.log" + $file = "$HOME\Documents\PC-Information.log" if (!(Test-Path $file)) { - New-Item -Path $file -Type File -Force + New-Item -Path $file -Type File -Force >> $null + Write-Host "Log file created at $file `n" -ForegroundColor "Yellow" } "----------------------------------------------------------" >> $file "Computer" >> $file @@ -175,6 +176,7 @@ function Output-To-File { #" Mac " $macaddress >> $file "---------------------------------------------------------" >> $file "" >> $file + } Main \ No newline at end of file diff --git a/RUN-ME.bat b/RUN-ME.bat index ebcdeb1..481e757 100644 --- a/RUN-ME.bat +++ b/RUN-ME.bat @@ -1,4 +1,4 @@ @echo off -mode con:cols=79 lines=37 +mode con:cols=82 lines=37 powershell -ExecutionPolicy Bypass .\Get-PC-Information.ps1 \ No newline at end of file