Fix copied row count

I had an issue with the row count being reported incorrectly when copying data if I altered the bHeader/bFooter options in my button config.

The existing code seemed not to account for the options passed to the button, so this commit ensures that those options are considered when determining row count to be displayed.