This error can occur when importing data into historical/provisional bank accounts. It's caused by the CSV file you're importing being open in another program, such as Excel or Notepad.
To fix this issue
Make sure the CSV file is not open in any other program, then try the import again.
Check what else is open
To see what other windows and programs are open on your computer, press and hold the Alt key on your keyboard then press the Tab key.