FormEditor.AddListItem
AddListItem(string, string)
向列表框添加新项。
public void AddListItem(string fieldName, string itemName)
| 参数 | 类型 | 描述 |
|---|---|---|
| fieldName | String | 要添加新项的字段名称。 |
| itemName | String | 新项的名称。 |
示例
FormEditor formEditor = new FormEditor("PdfForm.pdf", PdfForm_out.pdf");
formEditor.AddListItem("listBoxField", "Item 4 (New Item)");
另请参阅
- class FormEditor
- namespace Aspose.Pdf.Facades
- assembly Aspose.PDF
AddListItem(string, string[])
向现有列表框字段添加带有导出值的新项,仅适用于 AcroForm 组合框字段。
public void AddListItem(string fieldName, string[] exportName)
| 参数 | 类型 | 描述 |
|---|---|---|
| fieldName | String | 要添加项的字段名称。 |
| exportName | String[] | 表示带有导出值的新列表项的字符串数组,即(项标签,导出值)。 |
示例
FormEditor fe = new FormEditor("PdfForm.pdf", "FormEditor_AddListItem2.pdf");
fe.AddListItem("listboxField", new string[] { "4", "Item4(Added)" });
另请参阅
- class FormEditor
- namespace Aspose.Pdf.Facades
- assembly Aspose.PDF