Class PdfLoadedStateItemCollection
Represents the collection of loaded state item.
Inheritance
System.Object
PdfLoadedStateItemCollection
Implements
System.Collections.IEnumerable
Inherited Members
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.ToString()
Namespace: Syncfusion.Pdf.Parsing
Assembly: Syncfusion.Pdf.Base.dll
Syntax
public class PdfLoadedStateItemCollection : PdfCollection, IEnumerable
Examples
//Load an existing document
PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf");
// Getting the 'Gender' radio button field
PdfLoadedRadioButtonListField radiobuttonField = doc.Form.Fields["Gender"] as PdfLoadedRadioButtonListField;
// State Item collection
PdfLoadedStateItemCollection stateItemCollection = radiobuttonField.Items;
// Radio button field item
PdfLoadedRadioButtonItem radiobuttonItem = stateItemCollection[0] as PdfLoadedRadioButtonItem;
// Selected the item
radiobuttonItem.Checked = true;
doc.Save("LoadedForm.pdf");
doc.Close(true);
'Load an existing document
Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf")
' Getting the 'Gender' radio button field
Dim radiobuttonField As PdfLoadedRadioButtonListField = TryCast(doc.Form.Fields("Gender"), PdfLoadedRadioButtonListField)
' State Item collection
Dim stateItemCollection As PdfLoadedStateItemCollection = radiobuttonField.Items
' Radio button field item
Dim radiobuttonItem As PdfLoadedRadioButtonItem = TryCast(stateItemCollection(0), PdfLoadedRadioButtonItem)
' Selected the item
radiobuttonItem.Checked = True
doc.Save("LoadedForm.pdf")
doc.Close(True)
Constructors
PdfLoadedStateItemCollection()
Declaration
public PdfLoadedStateItemCollection()
Properties
Item[Int32]
Gets the PdfLoadedStateItem at the specified index.[Read-Only]
Declaration
public PdfLoadedStateItem this[int index] { get; }
Parameters
Type | Name | Description |
---|---|---|
System.Int32 | index |
Property Value
Type |
---|
PdfLoadedStateItem |
Examples
//Load an existing document
PdfLoadedDocument doc = new PdfLoadedDocument("SourceForm.pdf");
// Getting the 'Gender' radio button field
PdfLoadedRadioButtonListField radiobuttonField = doc.Form.Fields["Gender"] as PdfLoadedRadioButtonListField;
// State Item collection
PdfLoadedStateItemCollection stateItemCollection = radiobuttonField.Items;
// Radio button field item
PdfLoadedRadioButtonItem radiobuttonItem = stateItemCollection[0] as PdfLoadedRadioButtonItem;
// Selected the item
radiobuttonItem.Checked = true;
doc.Save("LoadedForm.pdf");
doc.Close(true);
'Load an existing document
Dim doc As PdfLoadedDocument = New PdfLoadedDocument("SourceForm.pdf")
' Getting the 'Gender' radio button field
Dim radiobuttonField As PdfLoadedRadioButtonListField = TryCast(doc.Form.Fields("Gender"), PdfLoadedRadioButtonListField)
' State Item collection
Dim stateItemCollection As PdfLoadedStateItemCollection = radiobuttonField.Items
' Radio button field item
Dim radiobuttonItem As PdfLoadedRadioButtonItem = TryCast(stateItemCollection(0), PdfLoadedRadioButtonItem)
' Selected the item
radiobuttonItem.Checked = True
doc.Save("LoadedForm.pdf")
doc.Close(True)
Implements
System.Collections.IEnumerable