Hi, I’m generating the pdf bytes using reportviewer render pdf. Before saving the pdf document on disk, I want to add the text stamp. But its not working and its not giving any error.
If I save the pdf on disk and open and if I do the text stamp, its working fine. But I want to do it before saving the pdf on disk.
Here is the sample code
TextStamp textStamp = new TextStamp(“SOME TEXT”);
textStamp.Background = true;
textStamp.XIndent = 370;
textStamp.YIndent = 740;
textStamp.TextState.Font = FontRepository.FindFont("Arial");
textStamp.TextState.FontSize = 15.0F;
textStamp.TextState.FontStyle = FontStyles.Bold;
for (int i = 1; i <= pdfDocument.Pages.Count; i++)
{
pdfDocument.Pages[i].AddStamp(textStamp);
}