Class FormElement
Namespace: IronPPT.Models.Abstract
Assembly: IronPPT.dll
Syntax
public abstract class FormElement : Object
Reach for FormElement when you need the common base behind interactive form controls on a slide. It marks a type as a form element, the shared parent the form controls inherit from, so code that handles them generically can treat a control as a FormElement regardless of its exact kind. A developer almost never names it directly; the concrete controls to work with are RadioButton and TextInput.
Because the class is abstract and exposes only a protected constructor, a FormElement is never created on its own. Instead a developer builds a RadioButton or a TextInput and, where it helps, holds or passes it as a FormElement so a single routine can accept any form control. That shared base is what lets a slide's interactive pieces be grouped and processed together.
The two derived controls add their own surface on top of this base: a RadioButton is the selectable option control and a TextInput the editable text field. Use the base when the distinction does not matter and the concrete type when it does. Treating the controls as FormElement keeps code that collects or iterates the form pieces simple, since it works against the one base rather than each control type.
The add slide how-to covers building slide content, and the slide element tutorial walks through the element model these controls fit into.
Constructors
FormElement()
Declaration
protected FormElement()