How To Add Watermark Text To Images in ASP.NET Using C#

By: Virendra
Updated: March 22, 2018 | Technology: Asp.Net, E-Commerce
How To Add Watermark Text To Images in ASP.NET Using C#

Prevention is better than preserve, Most of the time, we run websites/blogs, face issues of our images being copied and Used on other blogs. There are many techniques we can use to protect our copyrighted content and prevent people from doing so. One of them is watermarking our images with our logo or watermarking the website name on the images. In one of my project, I had to face the same Issue. In this article, Here I am going to propose a feasible solution to add Text and Image as a watermark on our Image/Photo using C#.

Follow these simple steps:

Steps:

  1. Select Image which you want to set Watermark.
    dddd
  2. Create two folder one is Imagtoor store your watermark logo image those you want to show on Image/Photo as a watermark.

    Create One more folder Img Watermark in this folder store the final image.

    sss

  3. Create a class i.e. a Watermarker in the App_Start folder to do that right-click on the App_Start folder then click on Add Items; select class gives it the name Watermarker.

    Note: Give the reference to “System.Windows.Forms

Copy to Clipboard
  1. In Controller write following code.
Copy to Clipboard

Please modify your Index Action for show image on UI:

Copy to Clipboard

Example:

dddddd

The source code shown in this article can be downloaded from here:

https://github.com/prajapatichintan/Add-Watermark-on-Image