Supported WPF Controls

Applies to TestComplete 15.63, last modified on April 23, 2024

TestComplete supports testing of various WPF controls. You can also modify project properties so that TestComplete recognizes your custom WPF controls. The sections below describe how you can test WPF controls in detail.

About Supported WPF Controls

TestComplete can work with any WPF control via a graphical user interface. Besides, TestComplete provides extended support for most of WPF controls. It automatically associates them with special scripting test objects that contain supplementary methods and properties for working with the controls, for example, for selecting individual items and retrieving the item text.

Requirements

  • A license for TestComplete Desktop module.

  • The WPF Control Support plugin. It provides access to controls via special program objects. It also enables creating table checkpoints for controls that display data in a tabular form. For the full list of these controls, see About Tables Collection.

This plugin is installed and enabled automatically.

If you experience issues when working with the controls, select File | Install Extensions from the TestComplete main menu to check whether the plugin is active. If the plugin is not available, run the TestComplete installation in the Repair mode.

Supported Component Versions

  • .NET Framework v. 3.0 - 4.8.

  • PowerBuilder .NET 12.0, 12.5, 12.5.2 and 12.6.

  • Microsoft Visual Studio 2010 - 2013 Shell.

Note: For information on the supported WPF Toolkit controls, see Supported Microsoft Controls.

Supported Classes

Below is the full list of the WPF controls for which TestComplete provides extended support.

Note that TestComplete provides support for the listed controls as well as for their descendants. However, to make this possible, you need to specify the class name of your inherited control in the corresponding group of the project’s Object Mapping options. For more information, see Object Mapping.

Controls Classes
Button System.Windows.Controls.Button
Microsoft.Windows.Controls.Ribbon.RibbonButton
Sybase.PowerBuilder.WPF.Controls.CommandButton
Sybase.PowerBuilder.WPF.Controls.ToolbarButton
Sybase.PowerBuilder.WPF.Controls.PictureButton
Microsoft.VisualStudio.PlatformUI.VsButton
Check box System.Windows.Controls.CheckBox
Microsoft.Windows.Controls.Ribbon.RibbonCheckBox
Sybase.PowerBuilder.WPF.Controls.CheckBox
Combo box System.Windows.Controls.ComboBox
Sybase.PowerBuilder.WPF.Controls.DropDownListBox
Sybase.PowerBuilder.WPF.Controls.DropDownPictureListBox
Edit System.Windows.Controls.TextBox
Sybase.PowerBuilder.WPF.Controls.MultiLineEdit
Sybase.PowerBuilder.WPF.Controls.SingleLineEdit
Expander System.Windows.Controls.Expander
List box System.Windows.Controls.ListBox
Sybase.PowerBuilder.WPF.Controls.ListBox
Sybase.PowerBuilder.WPF.Controls.PictureListBox
List view System.Windows.Controls.ListView
Sybase.PowerBuilder.WPF.Controls.ListView
Menu System.Windows.Controls.Menu
Sybase.PowerBuilder.WPF.Controls.Menu
Microsoft.VisualStudio.PlatformUI.VsMenu
Password edit          System.Windows.Controls.PasswordBox
Radio button System.Windows.Controls.RadioButton
Sybase.PowerBuilder.WPF.Controls.RadioButton
Repeat button System.Windows.Controls.Primitives.RepeatButton
Ribbon Microsoft.Windows.Controls.Ribbon.Ribbon
System.Windows.Controls.Ribbon.Ribbon
Scroll bar System.Windows.Controls.Primitives.ScrollBar
Sybase.PowerBuilder.WPF.Controls.HScrollBar
Sybase.PowerBuilder.WPF.Controls.VScrollBar
Scroll viewer System.Windows.Controls.ScrollViewer
System.Windows.Controls.FlowDocumentScrollViewer
System.Windows.Controls.DocumentViewer
TabControl System.Windows.Controls.TabControl
Sybase.PowerBuilder.WPF.Controls.Tab
Microsoft.VisualStudio.PlatformUI.Shell.Controls.TabGroupControl
Toggle button System.Windows.Controls.Primitives.ToggleButton
Microsoft.Windows.Controls.Ribbon.RibbonToggleButton         
Toolbar System.Windows.Controls.ToolBar
Sybase.PowerBuilder.WPF.Controls.Toolbar
Microsoft.VisualStudio.PlatformUI.VsToolBar
TrackBar System.Windows.Controls.Slider
Sybase.PowerBuilder.WPF.Controls.HTrackBar
Sybase.PowerBuilder.WPF.Controls.VTrackBar
Tree view System.Windows.Controls.TreeView
Sybase.PowerBuilder.WPF.Controls.TreeView
Note: If your WPF application contains a control that represents a collection of items (for example, a combo box or a list box), and the control uses data binding for its items, TestComplete may fail to access those items correctly. To get the items, you can use the control’s native properties.

Recognizing Custom Controls

To command TestComplete to recognize your custom WPF controls, open your project’s Object Mapping options and add the control’s class name to the corresponding subgroup of the WPF Controls group. The subgroup name corresponds to your custom control’s type. Once the control is mapped, it gets all the properties, methods and actions specific to the WPF control of the corresponding type.

If the specified custom control does not fit the control’s type, then it may not properly respond to commands that TestComplete sends, so recording or playing back user actions over the tested control will cause errors.

More Supported WPF Controls

See Also

Supported Controls
Testing WPF Applications
Support for WPF Applications' Controls
Support for WPF Control Templates

Highlight search results