How to insert image into RTF control

asp India
  • 13 years ago

    I have placed an RTF text box in an ASP page (classic) similar to the one which u use to post questions in developer fusion. However it does not have any tool bar as such. Whenever i copy an image from a word doc and paste it into the rtf control it displays <Object> tag instead of displaying the image but other formatted text are displayed appropriately if pasted. I may use any other control but using asp is the only option. I would like to know the method that will place and display the image in the text control. I won't mind if i have to place a button on the page that will browse for the image to be inserted into the control.


    The rtf control tag used is
    <!--
    <OBJECT id=RichText1 height=235 width=542
    classid=clsid:3b7c8860-d78f-101b-b9b5-04021c009402><PARAM NAME="_ExtentX" VALUE="14340"><PARAM NAME="_ExtentY" VALUE="6218"><PARAM NAME="_Version" VALUE="393217"><PARAM NAME="BackColor" VALUE="-2147483643"><PARAM NAME="BorderStyle" VALUE="1"><PARAM NAME="Enabled" VALUE="1"><PARAM NAME="HideSelection" VALUE="-1"><PARAM NAME="MultiLine" VALUE="-1"><PARAM NAME="ReadOnly" VALUE="0"><PARAM NAME="ScrollBars" VALUE="0"><PARAM NAME="MousePointer" VALUE="0"><PARAM NAME="DisableNoScroll" VALUE="0"><PARAM NAME="MaxLength" VALUE="0"><PARAM NAME="BulletIndent" VALUE="0"><PARAM NAME="Appearance" VALUE="1"><PARAM NAME="RightMargin" VALUE="0"><PARAM NAME="AutoVerbMenu" VALUE="0"><PARAM NAME="OLEDragMode" VALUE="1"><PARAM NAME="OLEDropMode" VALUE="2"><PARAM NAME="TextRTF" VALUE="{\rtf1\ansi\deff0{\fonttbl{\f0\fnil\fcharset0 Times New Roman;}}&#13;&#10;{\*\generator Riched20 5.40.11.2210;}\viewkind4\uc1\pard\lang1033\f0\fs24 RichText1&#13;&#10;\par }&#13;&#10;"></OBJECT>
    -->
    RICHTX32.ocx


    Please Help.

     

     

Post a reply

No one has replied yet! Why not be the first?

Sign in or Join us (it's free).

Contribute

Why not write for us? Or you could submit an event or a user group in your area. Alternatively just tell us what you think!

Our tools

We've got automatic conversion tools to convert C# to VB.NET, VB.NET to C#. Also you can compress javascript and compress css and generate sql connection strings.

“XML is like violence - if it's not working for you, you're not using enough of it.”