This is tutorial talks about how to automatically launch an application when a file changes. To do this, I will use a free command line utility, When_Changed. This tiny tool can watch a single file or a group of files of the same type. And when it detects changes like rename, delete, modification, etc., then it can execute a command, set by you. And this feature can be used to launch an application whenever a file changes in Windows.
This is quite a unique software which can be used to trigger the launch of an application. And I don’t know why you will need to use such software, but if you do, then this tutorial will help you. When _Changed keeps running in the command prompt and watch file changes. And if detects any, then it launches an application.
How to Automatically Launch an Application When File Changes?
When_Changed freeware lets you automatically launch an application when a file changes. And the best part is that you can use it to watch files having the same extension and in the action command, you can even use command line arguments.
These steps will help you automatically launch an application when a file changes in Windows.
Step 1: Download the EXE of When_Changed from here and then place in some folder of your choice.
Step 2: Open command prompt or PowerShell (in CMD mode) in the same folder and then you can use the following command in the same syntax.
when_changed "path to the file to watch" "command to execute"
Step 3: If you want it to watch multiple files, then you can use this command. In my case, I will be watching changes in TXT files.
when_changed "E:/*.txt" "command to execute"
With the help of these simple steps, you will be able to automatically launch an application when a file changes. And When_Changed makes it very easy to do that. You can make it launch almost any application. And its ability to watch file changes is quite noticeable. However, I would like to state one thing that to execute applications from “C:/ Program Files”, you will have to run it in administrator command prompt. Otherwise, the application will fail to launch.
When_Changed is quite a nice tool which can easily launch an application or run a command. This is helpful in case if any other software or application modifies a file, then you will know that. Also, you can use the same tool to open the changed file with the help of some other application.