This is a migrated thread and some comments may be shown as answers.

RadEditor: Adding watermark to html report

3 Answers 101 Views
Sharepoint Integration
This is a migrated thread and some comments may be shown as answers.
Jason
Top achievements
Rank 1
Jason asked on 10 Aug 2014, 05:04 PM
http://www.telerik.com/forums/water-mark-text

I have found and am a little confused by the way these examples work. This is the way my code is setup:

C# side

string reportResult = report.GetReport(**all parameters needed to make a dynamic html**);
RadEditorReportView.Content = reportResult;



.asp side

<
telerik:RadEditor ID="RadEditorReportView" Runat="server" Width="100%" EditModes="Preview" Height="100%"    ToolsWidth="0" Enabled="false">
            <Tools>
                <telerik:EditorToolGroup></telerik:EditorToolGroup>
            </Tools>
</telerik:RadEditor>

Now I am trying to add a Text Watermark as shown in this example: http://www.telerik.com/help/reporting/designing-reports-watermarks.html

So I am trying to do it 3 different ways and only 1 way needs to work listed in order by the way I prefer to do it most:

1. Code Behind. As you see I am just setting the Content to be an html string in my RadEditor. Do I need to create a System.Drawing.Image object?
2. asp side. Running asp code but it seems that it needs to create some sort of document object that I'm not doing here.
3. Designing Reports Watermarks link seems to be creating a type of Report that is not the same as what I'm trying to do here.

But it doesn't seem the Reports talked about here are an actual printed report but some sort of computer report. What I'm trying to accomplish is to add a watermark to files that we print in pdf format. The PDF files are already created. I just need to add watermarks now. How do I exactly add watermarks here? In the previous link therei s an example doing it in the asp side using OnClientLoad but we don't create an actual document here. What is the document that needs to be created to make this work? Or to do it from the code behind, I need to somehow make the html string into this object: System.Drawing.Image ???

3 Answers, 1 is accepted

Sort by
0
Jason
Top achievements
Rank 1
answered on 10 Aug 2014, 05:04 PM
Please ignore the very last paragraph.
0
Jason
Top achievements
Rank 1
answered on 11 Aug 2014, 05:21 AM
Can someone please help me? I cannot quite figure out the details.
0
Marin Bratanov
Telerik team
answered on 13 Aug 2014, 10:15 AM

Hello Jason,

The forum thread you linked modified the RadEditor content so it includes HTML that produces the desired watermark. If this is what you are after, you would need to modify the content string on the server to include an <img /> tag, or another tag with appropriate CSS rules. Another option is to modify the content area itself to have a watermark as shown here. In either case this is done with CSS/HTML and not with .NET objects.

The help article you linked is related to the Telerik Reporting toolset and is not applicable for RadEditor for ASP.NET AJAX. The reports have watermark functionality built in, but with RadEditor the developer must add it according to their logic and needs.

I hope this explains the situation.



Regards, Marin Bratanov
Telerik
 

Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.

 
Tags
Sharepoint Integration
Asked by
Jason
Top achievements
Rank 1
Answers by
Jason
Top achievements
Rank 1
Marin Bratanov
Telerik team
Share this question
or