Fast web view and pagenumber

Hi There, we are using aspose.net to optimize the pdfs and it works fine when we open the pdf without the pagenumber querystring. Is this a known issue?

Hi,

Thanks for using our products.

As per my understanding, you are facing an issue with Fast View web settings over PDF files when a PageNumber stamp is added over it. I have tested the scenario using Aspose.Pdf for .NET 8.5.0 where I have used the following code snippet to add a text stamp and enable Fast web viewing over the PDF file and, as per my observations, both options are properly applied.

In case I have not properly understood your problem, please share some further details. Also please share the code snippet and source PDF file. We are sorry for your inconvenience.

C#

//open document
Document pdfDocument = new Document("c:/pdftest/DowngradedFile.pdf");

//create text stamp
TextStamp textStamp = new TextStamp("Sample Stamp");

//set whether stamp is background
textStamp.Background = true;

//set origin
textStamp.XIndent = 100;
textStamp.YIndent = 100;

//rotate stamp
textStamp.Rotate = Rotation.on90;

//set text properties
textStamp.TextState.Font = FontRepository.FindFont("Arial");
textStamp.TextState.FontSize = 14.0F;
textStamp.TextState.FontStyle = FontStyles.Bold;
textStamp.TextState.FontStyle = FontStyles.Italic;
textStamp.TextState.ForegroundColor = Aspose.Pdf.Color.Aqua;

//add stamp to particular page
pdfDocument.Pages[1].AddStamp(textStamp);

// enable Fast web view
pdfDocument.Optimize();

//save output document
pdfDocument.Save("c:/pdftest/Stamped_FastWeb_output.pdf");

Thanks for the quick reply. They were two not related problem. We had two code base one rendering the PDFs as application/pdf and the other as partial view result. We tried to relate the unrelated combinations of issues.


Thanks again.

Hi,


From your above description, I am afraid I am unable to understand that your problem is resolved or it still persists. If the problem still persists, please share the code snippet and resource files, so that we can test the scenario at our end.

Sorry for confusing. I am good and this issue is put to rest.


Appreciate your support guys! Thank you so much.