Added count support for pasting