Runtime Image Watermark

Stimulsoft Reports.JS discussion
BCS
Posts: 83
Joined: Thu Nov 17, 2016 5:47 am

Re: Runtime Image Watermark

Post by BCS »

Okay answer me this then, is it possible to set the page area to a background image the same size as the report area? I thought an image watermark might achieve this. This issue has caused us to go behind project due date. Different quote reports will have different themes is the need for this.
Lech Kulikowski
Posts: 6245
Joined: Tue Mar 20, 2018 5:34 am

Re: Runtime Image Watermark

Post by Lech Kulikowski »

Hello,

We are still working on the issue. We will let you know about the result.

Thank you.
#7615
BCS
Posts: 83
Joined: Thu Nov 17, 2016 5:47 am

Re: Runtime Image Watermark

Post by BCS »

Thank you
Lech Kulikowski
Posts: 6245
Joined: Tue Mar 20, 2018 5:34 am

Re: Runtime Image Watermark

Post by Lech Kulikowski »

Hello,

We are working on the problem. We will let you know when the solution is available.

Thank you.
Lech Kulikowski
Posts: 6245
Joined: Tue Mar 20, 2018 5:34 am

Re: Runtime Image Watermark

Post by Lech Kulikowski »

Hello,

The issue is fixed. The fix will be available in the next release build.

Thank you.
BCS
Posts: 83
Joined: Thu Nov 17, 2016 5:47 am

Re: Runtime Image Watermark

Post by BCS »

Great I'll give it a try, though which part was fixed the runtime version of my code or the design time version? I was having trouble doing it either way outside of your own online designer and viewer on your domain.
Lech Kulikowski
Posts: 6245
Joined: Tue Mar 20, 2018 5:34 am

Re: Runtime Image Watermark

Post by Lech Kulikowski »

Hello,

Should work in runtime and design time.

Thank you.
BCS
Posts: 83
Joined: Thu Nov 17, 2016 5:47 am

Re: Runtime Image Watermark

Post by BCS »

Is it possible to post a hard example (with files) to demonstrate this, I'm still getting the same result. I've try it both in design time and run time. The water mark image will simple just not show when loaded and displayed. I just simply need to display an image as the reports background, this is for generating booklets and business quotes. Also need to be able to export this to pdf and in further reading this seems to not be implement in JS.

This is the runtime version of it:

Code: Select all

<!DOCTYPE html>
<html>
<head>
    <title>Report.mrt - Viewer</title>

    <link rel="stylesheet" type="text/css" href="../css/stimulsoft/stimulsoft.viewer.office2013.whiteblue.css">

    <script type="text/javascript" src="https://ajax.aspnetcdn.com/ajax/jquery/jquery-3.1.0.min.js"></script>
    <script>window.jQuery || document.write(decodeURIComponent('%3Cscript src="js/jquery.min.js"%3E%3C/script%3E'))</script>

    <script type="text/javascript" src="../js/stimulsoft/stimulsoft.reports.js"></script>
    <script type="text/javascript" src="../js/stimulsoft/stimulsoft.viewer.js"></script>

    <script type="text/javascript" src="https://ajax.aspnetcdn.com/ajax/jquery/jquery-3.1.0.min.js"></script>
</head>
<body>
<div id="viewerContent"></div>
<script>
    Stimulsoft.Base.StiLicense.loadFromFile("../license.key");

    var options = new Stimulsoft.Viewer.StiViewerOptions({showTooltips:false});
    var viewer = new Stimulsoft.Viewer.StiViewer(options, "StiViewer", false);
    var report = new Stimulsoft.Report.StiReport({isAsyncMode: true});

    report.loadFile("Backgroundimg.mrt");

    var page = report.pages.getByIndex(0);

    page.watermark.image = Stimulsoft.System.Drawing.Image.fromFile('test.jpg');
    page.watermark.aspectRatio = true;
    page.watermark.imageStretch = true;
    page.watermark.imageShowBehind= true;

    report.renderAsync(function () {
        viewer.report = report;
        viewer.renderHtml("viewerContent");
    });
</script>
</body>
</html>
Lech Kulikowski
Posts: 6245
Joined: Tue Mar 20, 2018 5:34 am

Re: Runtime Image Watermark

Post by Lech Kulikowski »

Hello,

The fix will be in the release 2019.1.2 which will release within one or two weeks.

Thank you.
BCS
Posts: 83
Joined: Thu Nov 17, 2016 5:47 am

Re: Runtime Image Watermark

Post by BCS »

Okay thank you I will keep checking back.
Post Reply