Specify main file
The load-task event comes with task and its index