ملائمة جميع أعمدة الصفحة العملية على صفحة PDF واحدة

ملائمة أعمدة صفحة العملية على صفحة PDF واحدة

تضمن PdfSaveOptions.all_columns_in_one_page_per_sheet أن تتم عرض كل الأعمدة في صفحة العملية على صفحة PDF واحدة، على الرغم من أن الصفوف قد تمتد إلى عدة صفحات اعتمادًا على البيانات في صفحة العملية.

الكود النموذجي أدناه يوضح كيفية استخدام PdfSaveOptions.all_columns_in_one_page_per_sheet لعرض صفحة عمل كبيرة تحتوي على 100 عمود.

from aspose.cells import PdfSaveOptions, SaveFormat, Workbook
# For complete examples and data files, please go to https:# github.com/aspose-cells/Aspose.Cells-for-.NET
# The path to the documents directory.
dataDir = RunExamples.GetDataDir(".")
# Create and initialize an instance of Workbook
book = Workbook(dataDir + "TestBook.xlsx")
# Create and initialize an instance of PdfSaveOptions
saveOptions = PdfSaveOptions(SaveFormat.PDF)
# Set AllColumnsInOnePagePerSheet to true
saveOptions.all_columns_in_one_page_per_sheet = True
# Save Workbook to PDF fromart by passing the object of PdfSaveOptions
dataDir = dataDir + "output.out.pdf"
book.save(dataDir, saveOptions)