On the dataset properties (on the page), what value do you have for “Mode”?
If it is not set to “Read-only” try changing the mode to read-only and then retry your code.

On the dataset properties (on the page), what value do you have for “Mode”?
If it is not set to “Read-only” try changing the mode to read-only and then retry your code.
