lansanniu
12 years agoOccasional Contributor
【help】catch exception in jscript
there is the js code below, I want to catch the ClickButton() exception, and go into the catch{} ,but I fail.
I found js can catch the error cause by itself, such as "alertt " (the correct is "alert"),
can not catch the error cause by TC9 item.
in a word , I hope I can catch any error ,and go into catch{}
---------------------------------------------------------------------------------------------
function Test1()
{
try{
Aliases.Xpoms_61.MainWindowRibbon.xtraTabControl.SOM_FundsManage_CashReserveRatio_CashReserveRatio.CashReserveRatio.groupControl1.btnModify.ClickButton();
}
catch(err){return "error";}
}