Posted by: Richard Siddaway
when relevant content is
added and updated.
Some of the events involved creating a CSV file. While it wasn’t explicitly asked that you opened the file many entrants chose to add that code to their scripts.
There were a number of options presented – most involving opening Excel and importing the CSV file.
There is a much quicker way
Invoke-Item -Path test.csv
Invoke-Item causes any file to open in the default application associated with that file. This will work for Office documents, text files and anything else that you can double click on a get it to open in an application.
If you use Invoke-Item on a .ps1 file – it will open in notepad just as if you’d double clicked it.