public static void Run() { // ExStart:AddPageStampAll // The path to the documents directory. string dataDir = RunExamples.GetDataDir_AsposePdfFacades_StampsWatermarks(); // Create PdfFileStamp object PdfFileStamp fileStamp = new PdfFileStamp(); // Open Document fileStamp.BindPdf(dataDir + "AddPageStampAll.pdf"); // Create stamp Aspose.Pdf.Facades.Stamp stamp = new Aspose.Pdf.Facades.Stamp(); stamp.BindPdf(dataDir + "temp.pdf", 1); stamp.SetOrigin(200, 200); stamp.Rotation = 90.0F; stamp.IsBackground = true; // Add stamp to PDF file fileStamp.AddStamp(stamp); // Save updated PDF file fileStamp.Save(dataDir + "AddPageStampAll_out.pdf"); // Close fileStamp fileStamp.Close(); // ExEnd:AddPageStampAll }
public static void Run() { // ExStart:AddPageStampAll // The path to the documents directory. string dataDir = RunExamples.GetDataDir_AsposePdfFacades_StampsWatermarks(); // Create PdfFileStamp object PdfFileStamp fileStamp = new PdfFileStamp(); // Open Document fileStamp.BindPdf(dataDir + "AddPageStampAll.pdf"); // Create stamp Aspose.Pdf.Facades.Stamp stamp = new Aspose.Pdf.Facades.Stamp(); stamp.BindPdf(dataDir+ "temp.pdf", 1); stamp.SetOrigin(200, 200); stamp.Rotation = 90.0F; stamp.IsBackground = true; // Add stamp to PDF file fileStamp.AddStamp(stamp); // Save updated PDF file fileStamp.Save(dataDir + "AddPageStampAll_out.pdf"); // Close fileStamp fileStamp.Close(); // ExEnd:AddPageStampAll }
public static void Run() { // The path to the documents directory. string dataDir = RunExamples.GetDataDir_AsposePdfFacades_StampsWatermarks(); //create PdfFileStamp object PdfFileStamp fileStamp = new PdfFileStamp(); //Open Document fileStamp.BindPdf(dataDir + "AddPageStamp-Page.pdf"); //create stamp Aspose.Pdf.Facades.Stamp stamp = new Aspose.Pdf.Facades.Stamp(); stamp.BindPdf(dataDir + "temp.pdf", 1); stamp.SetOrigin(200, 200); stamp.Rotation = 90.0F; stamp.IsBackground = true; //set particular pages stamp.Pages = new int[] { 2 }; //add stamp to PDF file fileStamp.AddStamp(stamp); //save updated PDF file fileStamp.Save(dataDir + "AddPageStamp-Page_out.pdf"); //close fileStamp fileStamp.Close(); }
public static void Run() { // The path to the documents directory. string dataDir = RunExamples.GetDataDir_AsposePdfFacades_StampsWatermarks(); //create PdfFileStamp object PdfFileStamp fileStamp = new PdfFileStamp(); //Open Document fileStamp.BindPdf(dataDir + "AddPageStamp-Page.pdf"); //create stamp Aspose.Pdf.Facades.Stamp stamp = new Aspose.Pdf.Facades.Stamp(); stamp.BindPdf(dataDir+ "temp.pdf", 1); stamp.SetOrigin(200, 200); stamp.Rotation = 90.0F; stamp.IsBackground = true; //set particular pages stamp.Pages = new int[] { 2 }; //add stamp to PDF file fileStamp.AddStamp(stamp); //save updated PDF file fileStamp.Save(dataDir + "AddPageStamp-Page_out.pdf"); //close fileStamp fileStamp.Close(); }
public static void Main() { // The path to the documents directory. string dataDir = Path.GetFullPath("../../../Data/"); //open document PdfFileStamp fileStamp = new PdfFileStamp(dataDir+ "input.pdf", dataDir+ "output.pdf"); //create stamp Aspose.Pdf.Facades.Stamp stamp = new Aspose.Pdf.Facades.Stamp(); stamp.BindPdf(dataDir+ "temp.pdf", 1); stamp.SetOrigin(200, 200); stamp.Rotation = 90.0F; stamp.IsBackground = true; //add stamp to PDF file fileStamp.AddStamp(stamp); //save updated PDF file fileStamp.Close(); }
public static void Main() { // The path to the documents directory. string dataDir = Path.GetFullPath("../../../Data/"); //open document PdfFileStamp fileStamp = new PdfFileStamp(dataDir + "input.pdf", dataDir + "output.pdf"); //create stamp Aspose.Pdf.Facades.Stamp stamp = new Aspose.Pdf.Facades.Stamp(); stamp.BindPdf(dataDir + "temp.pdf", 1); stamp.SetOrigin(200, 200); stamp.Rotation = 90.0F; stamp.IsBackground = true; //add stamp to PDF file fileStamp.AddStamp(stamp); //save updated PDF file fileStamp.Close(); }