Data behaviors (Blend SDK for WPF)

In Blend for Visual Studio 2012, you can use data behaviors to interact with data in a variety of ways, including adding and modifying properties by using a data store, applying visual state changes based on data comparisons, and triggering specific actions based on changes to the data store.

For more information about the data store, see Add or modify a data store (Blend SDK for WPF).

The InvokeCommandAction and CallMethodAction actions are particularly useful when you are working with Views and ViewModels.

Blend data behaviors

The following data behaviors are available in Blend:

  • CallMethodAction   Use the CallMethodAction action to call a method on the DataContext of an element when an event occurs.

    For more information about this action, see CallMethodAction (Blend SDK for WPF).

  • DataStateBehavior   Use the DataStateBehavior behavior to change a visual state based on whether a condition evaluates to True or to False.

    For more information about this behavior, see DataStateBehavior (Blend SDK for WPF).

  • FluidMoveSetTagBehavior   Use the FluidMoveSetTagBehavior behavior to create a data store or to write information to an existing data store.

    For more information about this behavior, see FluidMoveSetTagBehavior (Blend SDK for WPF).

  • InvokeCommandAction   Use the InvokeCommandAction action to invoke a command exposed by the data source.

    For more information about this action, see InvokeCommandAction (Blend SDK for WPF).

  • SetDataStoreValueAction   Use the SetDataStoreValueAction behavior to automatically adjust the values of your data store at run time.

    For more information about this action, see SetDataStoreValueAction (Blend SDK for WPF).

SketchFlow data behaviors

You can create prototypes that display data by using the sample data feature in Blend for Visual Studio 2012. You can use data behaviors to represent user interaction with data.

The following conditional behavior is available in SketchFlow:

  • RemoveItemInListBoxAction   Use RemoveItemInListBoxAction to demonstrate removing an item from a list box. The RemoveItemInListBoxAction behavior works only inside a data template, and only to remove the list-box item that it is associated with from the from the data-bound list box in which it resides.

    For more information about this behavior, see RemoveItemInListboxAction (Blend SDK for WPF).

Note

You can use all the behaviors in available in Blend in SketchFlow projects. However, SketchFlow behaviors are available only in SketchFlow projects.

See Also

Concepts

Working with built-in behaviors (Blend SDK for WPF)

Working with SketchFlow behaviors (Blend SDK for WPF)