Rich text and images

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • fabrou
    New Member
    • Jun 2008
    • 2

    Rich text and images

    I'm using .NET and C# and I'm having trouble finding a way to put images into a richtextbox. The example uses the clipboard, but that's no good. That would erase whatever is already there.

    I mean, come on. This is all Microsoft stuff. There must be a better way in .NET to add image into this format. They advertize that it can use fonts, colors, images, etc. So there should be a native way to do that.

    Also, is there any way to lock the image size in RTF so that it can't be resized?
  • r035198x
    MVP
    • Sep 2006
    • 13225

    #2
    Originally posted by fabrou
    I'm using .NET and C# and I'm having trouble finding a way to put images into a richtextbox. The example uses the clipboard, but that's no good. That would erase whatever is already there.

    I mean, come on. This is all Microsoft stuff. There must be a better way in .NET to add image into this format. They advertize that it can use fonts, colors, images, etc. So there should be a native way to do that.

    Also, is there any way to lock the image size in RTF so that it can't be resized?
    How did you try to add the images? Are you sure you are not running into the problems stated in
    Originally posted by MSDN docs
    While RichTextBox supports copying and pasting of images, certain scenarios are currently unsupported and may not work properly. The following table summarizes these scenarios and expected results.

    Comment

    • fabrou
      New Member
      • Jun 2008
      • 2

      #3
      Originally posted by r035198x
      How did you try to add the images? Are you sure you are not running into the problems stated in
      Thanks for your reply. That table seems to refer to copy/paste procedures. The whole point of this is to somehow get an image into rich text without having to use "paste".

      I simply want to insert an image (from a file or URL) into a richtext box, without having to manage/destroy the contents of the clipboard.

      Comment

      Working...