Skip to end of metadata
Go to start of metadata

Remarks

UXDataSearchBox is inherited from UXSearchBox which shares all the common features of UXSearchBox. In UXSearchBox, you need to create your own search provider and by checking the QueryText and IsSearching property. With the introduction of QueryDescriptor, UXDataSearchBox provides an easier way to search data through the QueryDescriptor integration.

To learn more about UXDataSearchBox, see UXDataSearchBox Overview.

Example

The following code shows how to use UXDataSearchBox to search your data using the QueryDescriptor feature.

View
GridViewModelBase
DataSearchBoxViewModel

 

Notice that you only need to bind the FilterDescriptors in your XAML and handle the QueryChanged in your ViewModel. The UXDataSearchBox will pass the filter descriptors based on FilterMemberPathFilterOperator and the user's input query.

If the FilterMemberPath property is not specified, UXDataSearchBox will use DisplayMemberPath for the filtering purpose.

Definition

public class UXDataSearchBox : UXSearchBox

Summary

The following table summarizes the members exposed in this class.

Public Constructors

UXDataSearchBox Constructor()Initializes a new instance of the UXDataComboBox class.

Public Properties

FilterDescriptorsGets or sets the descriptor object that encapsulates the filtering related information.
FilterMemberPathGets or sets member path used in the filter descriptor.
FilterOperatorGets or sets filter operator used in the filter descriptor.

Fields

FilterDescriptorsPropertyIdentifies the FilterDescriptors dependency property.
FilterMemberPathPropertyIdentifies the FilterMemberPath dependency property.
FilterOperatorPropertyIdentifies the FilterOperator dependency property.

Protected Methods


Public Constructors

public UXDataSearchBox()

Initializes a new instance of the UXDataComboBox class.

Public Properties

public CompositeFilterDescriptorCollection FilterDescriptors { get; set; }

Gets or sets the descriptor object that encapsulates the filtering related information.

public string FilterMemberPath { get; set; }

Gets or sets member path used in the filter descriptor.

public FilterOperator FilterOperator { get; set; }

Gets or sets filter operator used in the filter descriptor.

Fields

public static readonly DependencyProperty FilterDescriptorsProperty

Identifies the FilterDescriptors dependency property.

public static readonly DependencyProperty FilterMemberPathProperty

Identifies the FilterMemberPath dependency property.

public static readonly DependencyProperty FilterOperatorProperty

Identifies the FilterOperator dependency property.

Protected Methods

protected void OnQueryTextChanged()

 

  • No labels