SCAR Code:
Function ChooseOptionEx(Text: String; Color: Integer; Action: ActionOptions): Boolean;
Var
dtm_Top, dtm_Bottom, tx, ty, bx, by: Integer;
TPA: TPointArray;
Txt: String;
BB: TBox;
Begin
dtm_Top := DTMFromString('78DA632C626460606662C006186134480D2B1' +
'16A7889502342404D1511EE6920424D2F613500F96003A5');
dtm_Bottom := DTMFromString('78DA63F46162600800622C80114683D47812A' +
'1C68E801A5722ECB224428D2E613500B821037B');
FindColorsTolerance(TPA, 0, MSX1, MSY1, MSX2, MSY2, 0);
BB := GetTPABounds(TPA);
Txt := GetTextAtEx(BB.x1 + 2, BB.y1 + 1, 9, UpChars, False, False,
0, 0, 4674653, 14, False, tr_Letters);
If LowerCase(Trim(Txt)) = 'choose option' Then
Begin
If FindDTM(dtm_Top, tx, ty, MSX1, MSY1, MSX2, MSY2) Then
If FindDTM(dtm_Bottom, bx, by, tx, ty, MSX2, MSY2) Then
Begin
FindColorsTolerance(TPA, 4674653, tx, ty, bx, by, 0);
BB := GetTPABounds(TPA);
Result := FindTextTPA(Color, 0, BB.x1, BB.y1, BB.x2, BB.y2, Text, UpChars, Action);
End;
End;
FreeDTM(dtm_Top);
FreeDTM(dtm_Bottom);
End;