Thanks for Reply
Resolved now
try
{
int number = ${__jexl3((${FinPlanIDGen} + 0.0 ).intValue().toString())};
log.info("The converted integer is " + number);
vars.put("FinPlanIDGenerated", String.valueOf(number));
}
catch (Exception ex){
log.warn("Error in my script", ex);
throw ex; // elsewise JMeter will "swallow" the above exception
}
Thanks & Regards,
Shyam Kishor Panjiyar
-----Original Message-----
From: Shyam Panjiyar <[email protected]>
Sent: 10 May 2019 16:24
To: 'JMeter Users List' <[email protected]>
Subject: Want to get Integer value only from rational number
Hi ,
Could you please help with Bean Shell Sampler Script for below requirement :-
Input - String sequence from JSON Extractor as 123.0
Output - String sequence in variable as 123
Thanks & Regards,
Shyam Panjiyar
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]