Analyzing your prompt, please hold on...
An error occurred while retrieving the results. Please refresh the page and try again.
次のコードスニペットは、Aspose.PDF.Drawingライブラリでも動作します。
Aspose.PDF for .NETを使用してPDFファイルからページを削除できます。PageCollectionコレクションから特定のページを削除します。
// For complete examples and data files, visit https://github.com/aspose-pdf/Aspose.PDF-for-.NET
private static void DeletePageFromPdfFile()
{
// The path to the documents directory
var dataDir = RunExamples.GetDataDir_AsposePdf_Pages();
// Open PDF document
using (var document = new Aspose.Pdf.Document(dataDir + "DeleteParticularPage.pdf"))
{
// Delete a particular page
document.Pages.Delete(2);
// Save PDF document
document.Save(dataDir + "DeleteParticularPage_out.pdf");
}
}
Analyzing your prompt, please hold on...
An error occurred while retrieving the results. Please refresh the page and try again.