Copy binary data to clipboard
How can I copy binary data in the clipboard? For example if I pack the number 1 as a 4-byte little-endian integer I want my clipboard to show 00 00 00 01 For text data this is trivial, with the option of having unicode text or ascii text. Clipboard.SetData(DataFormats.Text, "Some text"); Clipboard.SetData(DataFormats.UnicodeText, "赤"); However for binary data I don't know what to do. There are actually two ways to do this: First one, and by far the simplest one: you simply put the byte array into the clipboard. This will automatically serialize the byte array, and deserialize it on retrieve,