I have a basic powershell GUI that I works fine. I compiled it with Powershell Tools and everything works correctly except for one portion. I open and format a txt file from a very specific location and display it in the window. I provide the exact path, and the error shows the correct path, stating the file is not here. I can copy the path into run and open the file.
Any idea on why this in particular would be an issue after converting the file to an executable?
The command I’m using is: Get-Content C:\Test\test.txt | Format-Table | Out-String
It’s stored as variable when the script runs, then displayed later when the function that does so is called.
Tool: Visual Studio, Visual Studio Code, PSScriptPad, PowerShell Module Version: