kwhitefoot Level: Trainee
 Registered: 01-08-2004 Posts: 1
|
Add picture to RichTextBox without clipboard and without activating editor
Is there any way of adding a picture to a RichTextBox without using the clipboard and without showing the editor for the picture?
I can use an OLE control to get show the insert object dialog and then use its class and sourcedoc properties as follows:
If I use RichTextBox.OLEObjects.Add, , , OLE1.Class then a new object of the relevant class is inserted and the editor for that class is activated in place but if I use RichTextBox.OLEObjects.Add, , OLE1.SourceDoc to create a picture (.bmp) from a file then instead of showing the picture the RichTextBox shows an icon and also the editor is activated but not in place. Instead it opens the associated application for files of that type.
So I really have two questions: how do I make sure that thne picture is shown and how do I suppress activation of the editor for the object?
|