A newer version of this page is available. Switch to the current version.

Banner Behavior

The Banner Behavior turns a PictureEdit editor into a simplified Image Slider that loops through a collection of images.

Behaviors - Banner Overview Animation

The behavior stores banner images that replace the original editor image after a certain delay.

Supported controls

Behavior options

  • Images - a collection of banner images. The behavior iterates through this collection and assigns images to the target editor's PictureEdit.Image property.
  • Interval - an amount of time (in milliseconds) it takes the editor to switch between images.
  • StartImmediatelly - a boolean property that specifies whether or not the editor should start displaying behavior images right away. If this property is disabled, the editor will start with its own original image.

Code sample

using DevExpress.Utils.Behaviors.Common;

behaviorManager1.Attach<BannerBehavior>(pictureEdit1, behavior => {
    behavior.Properties.StartImmediately = false;
    behavior.Properties.Interval = 3000;
    behavior.Properties.Images = new System.Drawing.Image[] {