Tip/Trick: How to kown the file that it's opening
Usually, our applications have files that only they can open. A perfect sample is the application I'm using to write it, Windows Live Writer, It has its own files with the "wpost" extension. This is posible because at the command prompt we can give it arguments. For example:
app.exe C:\samplefile.txt
The result of this command is the app running. But, running the application we can get this argument with the next function:
This function checks the file exists too.
This "feature" we can use to show the application hidden options. With the following command obtained from the Environment.GetCommandLineArgs function:
app.exe advanced