Hi
In my application we are using v2 telerik dll and following is the code used:
<rad:RadEditor ID="notificationDescriptionTextBox" runat="server" Width="89%" Height="150px" ToolsFile="~/library/RADControls/BasicTools.xml" RadControlsDir="~/RadControls/" ShowSubmitCancelButtons="false" StripFormattingOnPaste="Font,Span,MSWordRemoveAll,Css"></rad:RadEditor>
If I have some existing text in the RadEditor with some styles applied on it and thereafter if I copy any text from an alternate application i.e. word/onenote/etc., the copied text inherits the existing styles.My requirement is that the copied text should not inherit the existing text's styles and it should retain the bold.Please suggest me a solution to accomplish the requirement.
4 Answers, 1 is accepted
0

Rajani
Top achievements
Rank 1
answered on 24 Dec 2010, 11:20 AM
Can you please help me on this because it is a urgent requirement for me
0
Hello Rajani,
Can you please provide an example of the reported behavior? I need the initial content, the content that will be pasted and a video demonstrating your steps. You can record the video using Jing.
Greetings,
Rumen
the Telerik team
Can you please provide an example of the reported behavior? I need the initial content, the content that will be pasted and a video demonstrating your steps. You can record the video using Jing.
Greetings,
Rumen
the Telerik team
Browse the vast support resources we have to jump start your development with RadControls for ASP.NET AJAX. See how to integrate our AJAX controls seamlessly in SharePoint 2007/2010 visiting our common SharePoint portal.
0

Rajani
Top achievements
Rank 1
answered on 28 Dec 2010, 12:48 PM
Hi Rumen,
Please find the below steps for this requirement
1) Write some text in RadEditor control and apply some styles to that text (E.g: Text written by user) which is depicted in attached Initial Text-in-RadEditor.JPG file.
2) Write some text in Word/One Note/etc.. and apply some styles to that text(E.g: Text copied from other application) which is depicted in attached Text-in-Word.JPG. Here the Font Name Times New Roman, Font Size is 20, Bold, Font color is Red.
3) Copy the text from Word and paste into RadEditor (E.g: Text written by user Text copied from other application.) which is depicted in attached CopiedTextInRadEditor.JPG file.When the copied text is pasted into Radeditor ,it looses its original format and inherits the existing text's format.
Now my requirement is that the copied text should not inherit the format of the existing text and it should be plain and should retain the bold.
Please let me know if you need any other information.
Thanks in Advance,
Rajani
Please find the below steps for this requirement
1) Write some text in RadEditor control and apply some styles to that text (E.g: Text written by user) which is depicted in attached Initial Text-in-RadEditor.JPG file.
2) Write some text in Word/One Note/etc.. and apply some styles to that text(E.g: Text copied from other application) which is depicted in attached Text-in-Word.JPG. Here the Font Name Times New Roman, Font Size is 20, Bold, Font color is Red.
3) Copy the text from Word and paste into RadEditor (E.g: Text written by user Text copied from other application.) which is depicted in attached CopiedTextInRadEditor.JPG file.When the copied text is pasted into Radeditor ,it looses its original format and inherits the existing text's format.
Now my requirement is that the copied text should not inherit the format of the existing text and it should be plain and should retain the bold.
Please let me know if you need any other information.
Thanks in Advance,
Rajani
0
Hi Rajani,
You have set the StripFormattingOnPaste property to "Font,Span,MSWordRemoveAll,Css", which means that all color, font and span formatting will be stripped from the pasted content.
To achieve the desired effect you should set StripFormattingOnPaste="MSWord" or StripFormattingOnPaste="MSWord,Font".
The MSWordRemoveAll option strips not only the MS Word tags and attributes, but the font and color formatting.
You can see my test in the following video: http://screencast.com/t/W6qLoRlm.
Best regards,
Rumen
the Telerik team
You have set the StripFormattingOnPaste property to "Font,Span,MSWordRemoveAll,Css", which means that all color, font and span formatting will be stripped from the pasted content.
To achieve the desired effect you should set StripFormattingOnPaste="MSWord" or StripFormattingOnPaste="MSWord,Font".
The MSWordRemoveAll option strips not only the MS Word tags and attributes, but the font and color formatting.
You can see my test in the following video: http://screencast.com/t/W6qLoRlm.
Best regards,
Rumen
the Telerik team
Browse the vast support resources we have to jump start your development with RadControls for ASP.NET AJAX. See how to integrate our AJAX controls seamlessly in SharePoint 2007/2010 visiting our common SharePoint portal.