Click or drag to resize

PdfContentExtensionsSetValue Method

Sets the graphics state parameter value associated with the specified graphics state parameter key.

Supported graphics state parameter keys are listed in the first column of the Table 58 – Entries in a Graphics State Parameter Dictionary.


Namespace: SautinSoft.Pdf.Objects
Assembly: SautinSoft.Pdf (in SautinSoft.Pdf.dll) Version: 2026.7.1
Syntax
public static bool SetValue(
	this PdfContentFormat format,
	PdfName key,
	PdfBasicObject value
)

Parameters

format  PdfContentFormat
The PdfContentFormat where to set the graphics state parameter.
key  PdfName
The key of the graphics state parameter to set.
value  PdfBasicObject
The value of the graphics state parameter to set.

Return Value

Boolean
if the graphics state parameter with the specified key is supported; otherwise, .

Usage Note

In Visual Basic and C#, you can call this method as an instance method on any object of type PdfContentFormat. When you use instance method syntax to call this method, omit the first parameter. For more information, see Extension Methods (Visual Basic) or Extension Methods (C# Programming Guide).
Exceptions
ExceptionCondition
ArgumentNullExceptionformat or key is .
Remarks
If value that is being set is associated with another PdfDocument, this method will automatically clone it and associate the clone with the current PdfDocument.
See Also