Checkbox
Last updated
Was this helpful?
Last updated
Was this helpful?
The checkbox class represents a simple checkbox ui element that can be either in state "checked" or "unchecked" and can toggle between the two by clicking into the checkbox. In order to distinguish between the two states, both representations (checkedImageReference and uncheckedImageReference) need to be provided in the constructor. For many software models there will be many checkboxes used in the UI, but they all look the same. For this it makes sense to place the image representations in a common folder and refer to this for all checkboxes.
If there is more than one checkbox on a given screen and the model needs to be able to distinguish between them, then you should use the class that allows to identify a checkbox based on its label.
Namespace: Progile.TRIO.BaseModel Assembly: Progile.TRIO.BaseModel (in Progile.TRIO.BaseModel.dll)
Progile.TRIO.BaseModel.Checkbox
Creates a new Checkbox instance, that can be found within the provided filter. Both checkedImageReference and uncheckedImageReference are required.
Syntax:
Parameter
Description
tester
The tester interface.
displayName
checkedImageReference
uncheckedImageReference
useVisualSense
[filters]
Name
Description
Checks the checkbox if it is not already in the correct state. Else it logs that nothing was done.
Returns true if the image checked can be found, false if unchecked can be found and throws an exception if neither one or the other can be found.
Returns true if the unchecked representation can be found, false if checked representation can be found and throws an exception if neither one or the other can be found.
Unchecks the checkbox if it is not already in the correct state. Else it logs that nothing was done.
Type:
Type: The name of the element that will be used for logging and reporting of exceptions (customer facing).
Type: The image reference for the checked representation. This or the uncheckedImgRef will be used to locate the checkbox.
Type: The image reference for the unchecked representation. This or the checkedImgRef will be used to locate the checkbox.
Type: True if VisualSense should be used to find the element
Type: [ ] Typically a filter indicating the area of interest for the image searches.