Recently, I have been dealing with a number of defects that all come home to roost with Microsoft’s RichEd20.dll – or more accurately the variation between versions of the DLL.

The first issue was spotted when copying an OLE object from word and pasting it into a Rich Edit control hosted by my client’s application. It worked fine when Office 2000 was installed, but the formatting was broken once Office 2007 was installed. (The pasted object was rendered in two parts – an embedded object and a static metafile).

And bizarrely, copying and pasting an embedded image from one Rich Edit control to another crashes when using the RichEd20.dll that ships with XP, but works fine when using the version that ships with Office 2007.

In both cases the presence of some text on the clipboard as well as the OLE object, significantly altered the behaviour of the paste operation.

Joyfully I searched the web, but didn’t find much help, except for this blog entry from Murray Sargent that lists the various RichEd20.dll versions and where they may be found.

So, if you experience weird formatting (or worse) when pasting an OLE object into a rich edit control, check out what version(s) of RichEd20.dll you’ve got installed.





Leave a Reply

Your email address will not be published. Required fields are marked *