18 January 2026:
Sahi Pro is an enterprise grade test automation platform which can automate web, mobile, API, windows and java based applications and SAP.
This forum is now archived and is in read-only mode. Please continue discussions on our improved new Sahi Pro Community forum.
Sahi Pro is an enterprise grade test automation platform which can automate web, mobile, API, windows and java based applications and SAP.
How to know the length of a Variable.
How to know the length of a Variable. I have tried following codes:
$tamnt = new Array();
_set($len, $tamnt.length);
assuem $tamnt=6495
we need the length of $tamnt
the answer is 4
and
this one also
_set($len, ($tamnt).length);
Please correct my codes.
$tamnt = new Array();
_set($len, $tamnt.length);
assuem $tamnt=6495
we need the length of $tamnt
the answer is 4
and
this one also
_set($len, ($tamnt).length);
Please correct my codes.
Comments
$len = (""+$tamnt).length; //=4. you want the string length.
Btw, how can $tamnt be an Array if it is equal to 6495?!
We are storing the number in an array and then later trying to calculate the string length.