Stripping characters from windows clipboard with win32clipboard from excel

stephen.boulet at gmail.com stephen.boulet at gmail.com
Thu Sep 12 19:01:20 EDT 2013


I have an excel file. When I select cells, copy from excel, and then use win32clipboard to get the contents of the clipboard, I have a 131071 character string.

When I save the file as a text file, and use the python 3.3 open command to read its contents, I only have 80684 characters.

Excel (and  other programs too) appends a bunch of b'\x00' (or similar) characters.

Is there a pythonic way to strip these out?



More information about the Python-list mailing list