Populates the tasks from the data in global variable.