Forum Discussion
shankar_r
8 years agoCommunity Hero
I had time hence spent some time on it.
Run the below code then you will find is the issue.
var inspectedRate;
var obj = Aliases.myApp.frmDealCheck.frmFX.frmFX1_B.frmFXSold.txtFXO_Amount;
if (obj.Exists) {
inspectedRate = aqConvert.VarToStr(obj.wText);
if (inspectedRate == "") {
Log.Error("The value of FXRate is empty.");
return;
}
inspectedRate = aqString.Trim(inspectedRate);
try {
inspectedRate = aqConvert.VarToInt(inspectedRate)
} catch (e) {
Log.Error("Actual FXRate is " + inspectedRate + " - " + e.stack);
return;
}
var correctValue = 1938665;
if (inspectedRate == correctValue) {
Log.Checkpoint("The value of FXRate is correct.");
} else {
else Log.Error("The value of FXRate is incorrect.");
}
} else Log.Error("Object not found");