Error received on running script: An error occurred while opening the data file. The file is read only or it is already open
The data file is saved to a network location.
As the data file is on a network location, this could be caused by another user having the file open.
Save the data file locally (on the C: drive) and run the script.