Terry Ford wrote: >> FYI, the more generic answer is to put multiple formats on the >> clipboard. So if you are copying text to the clipboard you would >> put plain text and RTF data on the clipboard. That way >> applications that don't understand styled text can just use the >> plain text. For applications like word processors, they can use >> the more specialized RTF data to recreate the stylings. > > How would one do that using standard Rb commands?
Here is a sample piece of code. Note, you have to supply your own RTF data. Dim cb as Clipboard Dim rtfString as string ' Create a clipboard object. cb = new Clipboard ' Get the RTF data. rtfString = getMyRTF #if TargetWin32 ' Add the RTF data to the clipboard. cb.AddRawData(rtfString, "Rich Text Format") #elseif TargetMacOS ' Add the RTF data to the clipboard. cb.AddRawData(rtfString, "RTF ") #endif ' Put the text on the clipboard. cb.text = myText _______________________________________________ Unsubscribe or switch delivery mode: <http://www.realsoftware.com/support/listmanager/> Search the archives: <http://support.realsoftware.com/listarchives/lists.html>
