The log indicates that variable sheet is not initialized, therefore the null pointer exception is thrown. If you place a break point at
Chances are you’re gonna find sheet is empty. So perhaps the name of the sheet is incorrect. Or worse, the path to the file is wrong. You should consider and make sure those possibilities are not true.
Thanks @ThanhTo …
The same path is identified when i am running directly in Katalon. This Keyword i am using in almost all my test case to save my data… The issue is thrown for this keyword only when running same script in Jenkins.
@ThanhTo …You are right abut the path… When I’m using relative path in my script, Katalon is able to recognize the file path but Jenkins in unable to recognize hence above error is displayed while saving the data in excel.
I used full path now “C:\KatalonNew\FNolDetails.xlsx” and it worked. .
Earlier i was using “…\\FNolDetails.xlsx” in my script…
Relative path i used so that if other folks are using my script then i will work for them as well… Any suggestion?