# Instruction Class

> An object of the Instruction class is an element of the ConditionalInstruction class and represents actions that are execute´d when the corresponding conditions are fulfilled.

- **Product:** TX Text Control .NET for WPF
- **Section:** Reference
- **Kind:** Class
- **Introduced:** 28.0
- **Namespace:** `TXTextControl`
- **Package:** `TXTextControl.TextControl.WPF.SDK` (assembly `TXTextControl.dll`, from the private NuGet feed or Text Control Offline Packages)
- **.NET Framework:** reference `TXTextControl.dll` from the setup
- **Implements:** `System.IComparable`
- **Path:** TX Text Control .NET for WPF > Reference > TXTextControl > Instruction Class
- **Web URL:** https://docs.textcontrol.com/tx-text-control-dotnet-wpf/reference/txtextcontrol/instruction/
- **LLMs URL:** https://docs.textcontrol.com/tx-text-control-dotnet-wpf/reference/txtextcontrol/instruction/llms.txt
- **LLMs-Full URL:** https://docs.textcontrol.com/tx-text-control-dotnet-wpf/reference/txtextcontrol/instruction/llms-full.txt

---

## On This Page

- [Description](https://docs.textcontrol.com/tx-text-control-dotnet-wpf/reference/txtextcontrol/instruction/#description)
- [Syntax](https://docs.textcontrol.com/tx-text-control-dotnet-wpf/reference/txtextcontrol/instruction/#syntax)
- [Examples](https://docs.textcontrol.com/tx-text-control-dotnet-wpf/reference/txtextcontrol/instruction/#examples)
- [Members](https://docs.textcontrol.com/tx-text-control-dotnet-wpf/reference/txtextcontrol/instruction/#members)

---

## In This Section

- [Instruction Constructor](https://docs.textcontrol.com/tx-text-control-dotnet-wpf/reference/txtextcontrol/instruction/constructor/llms.txt): Initializes a new instance of the Instruction class to determine an action that is executed when the defined requirements of the ConditionalInstruction.Conditions array are fulfilled or not fulfilled.
- [Instruction.ElseInstructionValue Property](https://docs.textcontrol.com/tx-text-control-dotnet-wpf/reference/txtextcontrol/instruction/elseinstructionvalue-property/llms.txt): Gets the value that is set by the specified action when the defined requirements of the ConditionalInstruction.Conditions array are not fulfilled and the Instruction.IsElseInstructionEnabled property is set to true.
- [Instruction.FormField Property](https://docs.textcontrol.com/tx-text-control-dotnet-wpf/reference/txtextcontrol/instruction/formfield-property/llms.txt): Gets the FormField to which the specified action is executed.
- [Instruction.InstructionType Property](https://docs.textcontrol.com/tx-text-control-dotnet-wpf/reference/txtextcontrol/instruction/instructiontype-property/llms.txt): Gets the type of action to execute. It specifies how the instruction value and else instruction value is applied to the corresponding form field.
- [Instruction.InstructionTypes Enumeration](https://docs.textcontrol.com/tx-text-control-dotnet-wpf/reference/txtextcontrol/instruction/instructiontypes-enumeration/llms.txt): Determines the type of action to execute. The enumeration contains the following values:
- [Instruction.InstructionValue Property](https://docs.textcontrol.com/tx-text-control-dotnet-wpf/reference/txtextcontrol/instruction/instructionvalue-property/llms.txt): Gets the value that is set by the specified action when the defined requirements of the ConditionalInstruction.Conditions array are fulfilled.
- [Instruction.IsElseInstructionEnabled Property](https://docs.textcontrol.com/tx-text-control-dotnet-wpf/reference/txtextcontrol/instruction/iselseinstructionenabled-property/llms.txt): Gets or sets a value indicating whether this Instruction allows to execute else instructions. If this property is set to true, the else instruction value is applied by the specified action when the defined requirements of the ConditionalInstruction.Conditions array are not fulfilled. The default value is false, if no else instruction value was set by the instruction constructor. Otherwise true.
- [Instruction.IsFormFieldChangeInstruction Property](https://docs.textcontrol.com/tx-text-control-dotnet-wpf/reference/txtextcontrol/instruction/isformfieldchangeinstruction-property/llms.txt): Gets or sets a value indicating whether this Instruction listens to value changes of the related conditions' form fields. If this property is set to false, the instruction ignores any form field change that would cause an action. Otherwise the corresponding actions are executed. The default value is true.
- [Instruction.IsInitialInstruction Property](https://docs.textcontrol.com/tx-text-control-dotnet-wpf/reference/txtextcontrol/instruction/isinitialinstruction-property/llms.txt): Gets or sets a value indicating whether this Instruction is handled when the document is initialized as a form. By default, all conditional instructions are applied when the document is changed to or loaded as a form. In this context, if this property is set to false, the instruction does not execute any actions, even if the requirements are fulfilled. The default value is true.

---

## Nearby

- **Previous:** [InputPosition.TextPosition Property](https://docs.textcontrol.com/tx-text-control-dotnet-wpf/reference/txtextcontrol/inputposition/textposition-property/llms.txt)
- **Next:** [Instruction Constructor](https://docs.textcontrol.com/tx-text-control-dotnet-wpf/reference/txtextcontrol/instruction/constructor/llms.txt)
