Quote:
Originally Posted by oXiDe
Problem with the Paste Method is it deletes the user's clipboard... We don't want that.. hmmm
|
The good practice in this case is to take what's there and put it back when you're done borrowing the users clipboard.
Code:
Dim o As IDataObject = Clipboard.GetDataObject
'borrow clipboard
Clipboard.SetDataObject(o)
Quote:
At the moment, we are coverting it into a WMF, then into RTF then into the RTB
...
I used the copy and paste method and received the exact same string
|
Are you sure it is the exact same? I also can load the image by setting the Rtf just fine. I noticed your string has upper case hex values, while the string produced by pasting the image has lower case hex. Did a test where I converted the hex data to upper and assigned Rtf, no problem with this also, the RTB just converts is to lower again when parsing the input data. Another difference is the string that is returned from Rtf property has linefeeds (not par's), but I can also confirm this don't affect the outcome. Apart from that I can't compare any differences, but you should make sure yours is.