Click or drag to resize

PdfDictionaryAdd Method

Adds the specified key and value to the dictionary.

Namespace: SautinSoft.Pdf.Objects
Assembly: SautinSoft.Pdf (in SautinSoft.Pdf.dll) Version: 2024.11.26
Syntax
public void Add(
	PdfName key,
	PdfBasicObject value
)

Parameters

key  PdfName
The key of the entry to add.
value  PdfBasicObject
The value of the entry to add. The value cannot be . Use Null value instead.

Implements

IDictionaryTKey, TValueAdd(TKey, TValue)
Exceptions
ExceptionCondition
InvalidOperationExceptionThe current PdfDictionary is read-only (IsReadOnly returns ).
ArgumentNullExceptionkey or value is .
ArgumentExceptionAn entry with the same key already exists in the PdfDictionary or value is already contained in some other PdfBasicObject or is PdfStream or is the current PdfDictionary.
See Also