Class TableGenerator
معلومات
يمثل مكون Documentize.TableGenerator. يُستخدم لإضافة جدول إلى مستند PDF.
[Obsolete("يرجى استخدام فئة PdfManager. سيتم حذف الفئة قريبًا.")]
public static class TableGeneratorوراثة
الأعضاء الموروثة
- object.GetType(),
- object.MemberwiseClone(),
- object.ToString(),
- object.Equals(object?),
- object.Equals(object?, object?),
- object.ReferenceEquals(object?, object?),
- object.GetHashCode()
أمثلة
توضح المثال كيفية إضافة جدول إلى ملف PDF.
// تكوين خيارات الجدول
var options = new TableOptions().InsertPageBefore(1)
.AddTable()
.AddRow()
.AddCell().AddParagraph("الاسم")
.AddCell().AddParagraph("العمر")
.AddRow()
.AddCell().AddParagraph("بوب")
.AddCell().AddParagraph("12")
.AddRow()
.AddCell().AddParagraph("سام")
.AddCell().AddParagraph("20")
.AddRow()
.AddCell().AddParagraph("ساندي")
.AddCell().AddParagraph("26")
.AddRow()
.AddCell().AddParagraph("توم")
.AddCell().AddParagraph("12")
.AddRow()
.AddCell().AddParagraph("جيم")
.AddCell().AddParagraph("27");
// إضافة مسار ملف الإدخال
options.AddInput(new FileDataSource("path_to_input.pdf"));
// تعيين مسار ملف الإخراج
options.AddOutput(new FileDataSource("path_to_output.pdf"));
// تنفيذ العملية
TableGenerator.Process(options);الطرق
Process(TableOptions)
أضف جدولاً إلى مستند PDF.
public static ResultContainer Process(TableOptions options)المعلمات
optionsTableOptions: كائن خيارات يحتوي على تعليمات للعملية.
المخرجات
ResultContainer : كائن يحتوي على نتيجة العملية.
الاستثناءات
إذا لم يتم تعيين الخيارات.
Namespace: Documentize Assembly: Documentize.dll