Flex APIs

abstract Sahi supports Flex applications via the Sahi Flex Library (SFL) Information on usage can be found here

_flex

Since: Sahi ProDesktop Add-OnMobile Add-OnSAP Add-OnAI Assist Add-On
3.5NANANANA

Available for modes: Browser

_flex($identifier)

Arguments
$identifierstring id of flex object

Returns
objectFlex object

Sahi Pro Flowcharts Action :Flex

Details

Returns a handle to the flex object. All child elements of the flex object are accessed from this handle.

_setValue(_flex("mxComponents").textinput("txt1"), "English");


info_flex is the same as _f
Information on usage can be found here


_f

Since: Sahi ProDesktop Add-OnMobile Add-OnSAP Add-OnAI Assist Add-On
3.6NANANANA

Available for modes: Browser

_f($identifier)

Arguments
$identifierstring id of flex object

Returns
objectFlex object

Sahi Pro Flowcharts Action :F

Details

info_f is the same as _flex
Returns a handle to the flex object. All child elements of the flex object are accessed from this handle.

_setValue(_f("mxComponents").textinput("txt1"), "English");
Information on usage can be found here


_setFlexReadyCondition

Since: Sahi ProDesktop Add-OnMobile Add-OnSAP Add-OnAI Assist Add-On
4.0NANANANA

Available for modes: Browser

_setFlexReadyCondition($fn)

Arguments
$fnfunction Function which evaluates to true/false. Function denotes when the flex app is considered to be ready for Sahi.

Returns
null

Sahi Pro Flowcharts Action :Set Flex Ready Condition

Details

This function should be used inside a browser tag. The $fn is called for each flex app on the browser, and the current flex app is passed as an argument to fn.

In some flex apps with lots of dynamically loading parts, it may be customary to show a rotating icon with "Loading..." or some such message. Sahi can be told to wait till this message disappears.

At the start of your script add this:
<browser>
_setFlexReadyCondition(function(fl){
  return !_isVisible(fl.uitextfield("Loading..."));
});
</browser>