Class CustomLookupTextBox
The Lookup textbox is a usercontrol for selecting and validating data from an custom source. All sources must be inherit from IValueSelectionProver, such as the ItemBoxSelectionProvider.
Inheritance
Namespace: Simplic.PlugIn.Logistics
Assembly: Simplic.PlugIn.Logistics.dll
Syntax
public sealed class CustomLookupTextBox : LookupTextBoxBase
Constructors
| Improve this Doc View SourceCustomLookupTextBox()
Create a new lookup textbox and all its components.
Declaration
public CustomLookupTextBox()
Fields
| Improve this Doc View SourceIdentityProperty
Dependency property which represents the identity of the current LookupTextbox. If the property is set, the find method will be called and the system try to resolve it
Declaration
public static readonly DependencyProperty IdentityProperty
Field Value
Type | Description |
---|---|
System.Windows.DependencyProperty |
IsReadOnlyProperty
Dependency property which represents the IsReadOnly-Flag of the current LookupTextbox. If the property is set, textboxes and buttons will be readonly too
Declaration
public static readonly DependencyProperty IsReadOnlyProperty
Field Value
Type | Description |
---|---|
System.Windows.DependencyProperty |
MergedIsTabStopProperty
Dependency property which represents the MergedIsTabStopProperty-Flag of the current LookupTextbox. If the property is set, textboxes and buttons will be included in tab navigation.
Declaration
public static readonly DependencyProperty MergedIsTabStopProperty
Field Value
Type | Description |
---|---|
System.Windows.DependencyProperty |
Properties
| Improve this Doc View SourceErrorBorderBrush
Brush of the input textfield border if the validation failed
Declaration
public Brush ErrorBorderBrush { get; set; }
Property Value
Type | Description |
---|---|
System.Windows.Media.Brush |
Identity
Identity property, call on property changed when used
Declaration
public object Identity { get; set; }
Property Value
Type | Description |
---|---|
System.Object |
IsReadOnly
IsReadOnly property for making things readable but not changeable
Declaration
public object IsReadOnly { get; set; }
Property Value
Type | Description |
---|---|
System.Object |
MergedIsTabStop
Gets or sets a value that indicates whether a control is included in tab navigation.
Declaration
public bool? MergedIsTabStop { get; set; }
Property Value
Type | Description |
---|---|
System.Nullable<System.Boolean> |
Provider
Get the current registered provider
Declaration
public IValueSelectionProvider Provider { get; set; }
Property Value
Type | Description |
---|---|
IValueSelectionProvider |
Result
Current result object
Declaration
public SelectorLookupResult Result { get; }
Property Value
Type | Description |
---|---|
SelectorLookupResult |
ShowIdentityTextBox
Defines if the scond textbox should be shown or not (Identity-TextBox)
Declaration
public bool ShowIdentityTextBox { get; set; }
Property Value
Type | Description |
---|---|
System.Boolean |
ShowValueSelectorKey
Set the key on which the selection provider should open and select a value
Declaration
public Key ShowValueSelectorKey { get; set; }
Property Value
Type | Description |
---|---|
System.Windows.Input.Key |
Methods
| Improve this Doc View SourceFocusInputBox()
Focus the input-textbox of this control
Declaration
public void FocusInputBox()
Initialize(IValueSelectionProvider)
Initialize a new selection provider. This must only done on setting up a new window
Declaration
public void Initialize(IValueSelectionProvider provider)
Parameters
Type | Name | Description |
---|---|---|
IValueSelectionProvider | provider | Instance of a selection provider |
OnGotFocus(RoutedEventArgs)
Got focus redirect to textbox
Declaration
protected override void OnGotFocus(RoutedEventArgs e)
Parameters
Type | Name | Description |
---|---|---|
System.Windows.RoutedEventArgs | e |
OnGotKeyboardFocus(KeyboardFocusChangedEventArgs)
Got focus redirect to textbox
Declaration
protected override void OnGotKeyboardFocus(KeyboardFocusChangedEventArgs e)
Parameters
Type | Name | Description |
---|---|---|
System.Windows.Input.KeyboardFocusChangedEventArgs | e |
SetDependentLookupTextBox(CustomLookupTextBox, Object[])
Make this LookupTextBox depending of another lookup textbox result
Declaration
public void SetDependentLookupTextBox(CustomLookupTextBox dependentTextBox, params object[] parameter)
Parameters
Type | Name | Description |
---|---|---|
CustomLookupTextBox | dependentTextBox | Instance of a lookup textbox |
System.Object[] | parameter | Parameter which will be passed to the Lookup-Interface |
SetOnAddItem(CustomLookupTextBox.AddItem)
Set the delegate which will be called, if an item should be added
Declaration
public void SetOnAddItem(CustomLookupTextBox.AddItem onAddItemDelegate)
Parameters
Type | Name | Description |
---|---|---|
CustomLookupTextBox.AddItem | onAddItemDelegate | Pointer to the add function |
SetValidationResult(SelectorLookupResult, Boolean)
Set validated valies on the ui
Declaration
public void SetValidationResult(SelectorLookupResult result, bool setIdentityProperty = true)
Parameters
Type | Name | Description |
---|---|---|
SelectorLookupResult | result | Object containing all information for setting the validation result |
System.Boolean | setIdentityProperty | Defines whether to set the identity property and bind |
Events
| Improve this Doc View SourceSelectionChanged
Will be called if the selection changed
Declaration
public event CustomLookupTextBox.SelectionChangedHandler SelectionChanged
Event Type
Type | Description |
---|---|
CustomLookupTextBox.SelectionChangedHandler |