There are 2 common reasons for why you may be able to read data flash, but are unable to write to data flash.
1) The device has a permanent failure. Check the PF Status register in EVSW. If there are any flags set, you have a permanent failure. The permanent failure must be cleared before data flash can be written again.
2) The battery voltage is below the Flash Update OK Voltage located in the data flash Power class. Charge the battery voltage above this threshold to allow write access again.