Control Definition XML Overview Schema

Description

This Help file describes the elements and attributes available for creating the control definition XML files for your .NET add-in extensibility project.

Most Custom Servers are implemented as a .NET DLL. Another coding option to extend support for custom .NET Windows Forms controls is by creating a control definition XML file for each custom control.

You can implement custom control support without programming a .NET DLL by entering the appropriate Test Record and Test Run instructions in control definition XML files (one for each control). You can instruct UFT to load the instructions by specifying the names of the control definition XML files in the UFT Windows Forms Extensibility Configuration file, SwfConfig.xml.

In a control definition XML file, you define:

  • A Record element if you want to customize recording on the control. A Record element includes Event elements in which you define how to record steps for different events that occur on the control.
  • A Replay element if you want to customize how test steps are run on a custom control. Each Replay element must include a Method element that specifies both Parameters and the MethodBody (implementation code) for the test object method you are customizing.
The Record and Replay elements are contained within one Customization element, which represents the control definition as a whole.

Elements

ElementDescription
CustomizationThe root element.
EventThe instructions for adding a step to the test or component when an event occurs on the control during a recording session.
EventsA collection of Event elements.
MethodThe implementation for a customized test object method.
MethodBodyA series of C# instructions to perform on the custom control when the test object method is called during a test run.
MethodsA collection of Method elements.
ParameterA test object method argument.
ParametersA collection of Parameter elements within a Method element.
RecordThe instructions for customized recording on the control.
RecordedCommandThe step that UFT should add to the test when the event described in the parent Event element occurs.
ReplayThe instructions for running customized test object methods on the control.