Child pages
  • Number

Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Wiki Markup
{hiddendiv:style=display:none}
DO NOT EDIT THE CONTENT OF THIS PAGE DIRECTLY (EXCEPT INSIDE THE DIV BELOW WITH ID=DESCRIPTION), UNLESS YOU KNOW WHAT YOU'RE DOING.
		THE STRUCTURE OF THE CONTENT IS VITAL IN BEING ABLE TO EXTRACTAUTO CHANGESUPDATE FROM THE PAGECONTENT ANDTHROUGH MERGETHE THEM BACK INTO SERVOY SOURCE{hiddenDOC GENERATOR{div}
{sub-sectiondiv:id=description|text=}{sub-sectiondiv}\\ 

{table:id=|class=servoy sSummary}{colgroup}{column:width=80px|padding=0px}{column}{column}{column}{colgroup}{tr:style=height: 30px;}{th:colspan=2}Property Summary{th}{tr}{tbody}{tr}{td}[Number]{td}{td}[#MAX_VALUE]
The largest representable number.{td}{tr}{tbody}{tbody}{tr}{td}[Number]{td}{td}[#MIN_VALUE]
The smallest representable number.{td}{tr}{tbody}{tbody}{tr}{td}[Number]{td}{td}[#NEGATIVE_INFINITY]
Special value representing negative infinity; returned on overflow.{td}{tr}{tbody}{tbody}{tr}{td}[Object]{td}{td}[#NaN]
Special "not a number" value.{td}{tr}{tbody}{tbody}{tr}{td}[Number]{td}{td}[#POSITIVE_INFINITY]
Special value representing infinity; returned on overflow.{td}{tr}{tbody}{table}\\ 

{table:id=|class=servoy sSummary}{colgroup}{column:width=80px|padding=0px}{column}{column}{column}{colgroup}{tr:style=height: 30px;}{th:colspan=2}Method Summary{th}{tr}{tbody}{tr}{td}[String]{td}{td}[#toExponential]\()
Returns a string representing the number in exponential notation.{td}{tr}{tbody}{tbody}{tr}{td}[String]{td}{td}[#toExponential]\(fractionDigits)
Returns a string representing the number in exponential notation.{td}{tr}{tbody}{tbody}{tr}{td}[String]{td}{td}[#toFixed]\()
Returns a string representing the number in fixed\-point notation.{td}{tr}{tbody}{tbody}{tr}{td}[String]{td}{td}[#toFixed]\(digits)
Returns a string representing the number in fixed\-point notation.{td}{tr}{tbody}{tbody}{tr}{td}[String]{td}{td}[#toLocaleString]\()
Converts the number into a string which is suitable for presentation in the given locale.{td}{tr}{tbody}{tbody}{tr}{td}[String]{td}{td}[#toPrecision]\()
Returns a string representing the number to a specified precision in fixed\-point or exponential notation.{td}{tr}{tbody}{tbody}{tr}{td}[String]{td}{td}[#toPrecision]\(precision)
Returns a string representing the number to a specified precision in fixed\-point or exponential notation.{td}{tr}{tbody}{tbody}{tr}{td}[String]{td}{td}[#toString]\()
Returns a string representing the specified Number object.{td}{tr}{tbody}{tbody}{tr}{td}[String]{td}{td}[#toString]\(radix)
Returns a string representing the specified Number object.{td}{tr}{tbody}{table}\\ 

{table:id=property|class=servoy sDetail}{colgroup}{column:width=100%|padding=0px}{column}{colgroup}{tr:style=height: 30px;}{th:colspan=1}Property Details{th}{tr}{tbody:id=MAX_VALUE|class=node}{tr:id=name}{td}h6.MAX_VALUE{td}{tr}{builder-show:permission=edit}{tr:id=desret}{td}{sub-section:MAX_VALUE_des|trigger=button|text=}{sub-section}{sub-section:MAX_VALUE_des|trigger=none|class=sIndent}Replace with description{sub-section*Returns*\\{div:class=sIndent}[Number]{div}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=sncsam}{td}*SinceSample*\\{sub-section:MAX_VALUE_snc|trigger=button|text=}{sub-section}{sub-section:MAX_VALUE_snc|trigger=none|class=sIndent} Replace with version info{sub-sectiondiv:class=sIndent}{code:language=javascript}
application.output("Largest number: " + Number.MAX_VALUE);
{code}{div}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{builder-showtbody}{builder-showtbody:permissionid=editMIN_VALUE}{tr:id=prsname}{td}*Parameters*\\{sub-section:MAX_VALUE_prs|trigger=button|text=}{sub-section}{sub-section:MAX_VALUE_prs|trigger=none|class=sIndent}{sub-sectionh6.MIN_VALUE{td}{tr}{tr:id=ret}{td}*Returns*\\{div:class=sIndent}[Number]{div}{td}{tr}{builder-show}{tr:id=retsam}{td}*ReturnsSample*\\{sub-section:MAX_VALUE_ret|trigger=button|text=}{sub-section}{sub-section:MAX_VALUE_ret|trigger=none|class=sIndent}[Number]{sub-sectiondiv:class=sIndent}{code:language=javascript}
application.output("Smallest number: " + Number.MIN_VALUE);
{code}{div}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{builder-showtbody:permissionid=editNEGATIVE_INFINITY}{tr:id=seename}{td}*Also see*\\{sub-section:MAX_VALUE_see|trigger=button|text=}{sub-section}h6.NEGATIVE_INFINITY{td}{tr}{tr:id=ret}{td}*Returns*\\{div:class=sIndent}{sub-section:MAX_VALUE_see|trigger=none}{sub-section}[Number]{div}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=linksam}{td}*External linksSample*\\{sub-section:MAX_VALUE_link|trigger=button|text=}{sub-section}{div:class=sIndent}{sub-section:MAX_VALUE_link|trigger=none}{sub-sectiondiv:class=sIndent}{code:language=javascript}
application.output("Negative infinity: " + Number.NEGATIVE_INFINITY);
{code}{div}{td}{tr}{builder-show}{tr:idclass=samlastDetailRow}{td}*Sample*\\{sub-section:MAX_VALUE_sam|trigger=button|text=}{sub-section}{div:class=sIndent}{sub-section:MAX_VALUE_sam|trigger=none}{code:language=javascript}
application.output("Largest number: " + Number.MAX_VALUE);
{code}{sub-section}{div}{td}{tr}{tr:class=lastDetailRow}{td{td}{tr}{tbody}{tbody:id=NaN}{tr:id=name}{td}h6.NaN{td}{tr}{tr:id=ret}{td}*Returns*\\{div:class=sIndent}[Object]{div}{td}{tr}{tbody}{tbodytr:id=MIN_VALUE|class=nodesam}{td}*Sample*\\{div:class=sIndent}{code:language=javascript}
application.output("NaN: " + Number.NaN);
{code}{div}{td}{tr}{tr:idclass=namelastDetailRow}{td}h6.MIN_VALUE{td}{tr}{builder-show:permission=edittbody}{tbody:id=POSITIVE_INFINITY}{tr:id=des}name}{td}h6.POSITIVE_INFINITY{td}{sub-section:MIN_VALUE_des|trigger=button|text=}{sub-section}{sub-section:MIN_VALUE_des|trigger=none|class=sIndent}Replace with description{sub-sectiontr}{tr:id=ret}{td}*Returns*\\{div:class=sIndent}[Number]{div}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=sncsam}{td}*SinceSample*\\{sub-section:MIN_VALUE_snc|trigger=button|text=}{sub-section}{sub-section:MIN_VALUE_snc|trigger=none|class=sIndent} Replace with version info{sub-sectiondiv:class=sIndent}{code:language=javascript}
application.output("Positive infinity: " + Number.POSITIVE_INFINITY);
{code}{div}{td}{tr}{tr:class=lastDetailRow}{builder-showtd}{builder-show:permission=edittd}{tr:id=prs}{tbody}{tdtable}*Parameters*\\{sub-section:MIN_VALUE_prs|trigger=button|text=}{sub-section}{sub-section:MIN_VALUE_prs|trigger=none|class=sIndent}{sub-section}{td}{tr}{builder-show 

{table:id=function|class=servoy sDetail}{colgroup}{column:width=100%|padding=0px}{column}{colgroup}{tr:style=height: 30px;}{th:colspan=1}Method Details{th}{tr}{tbody:id=toExponential}{tr:id=retname}{td}*Returns*\\{sub-section:MIN_VALUE_ret|trigger=button|text=}{sub-section}{sub-section:MIN_VALUE_ret|trigger=none|class=sIndent}[Number]{sub-sectionh6.toExponential{td}{tr}{tr:id=sig}{td}{span:style=margin-right: 5px;}[String]{span}{span:style=font-weight: bold;}toExponential{span}{span}\(){span}{td}{tr}{builder-showtr:permissionid=editret}{tr:id=see}{td}*Also seeReturns*\\{sub-section:MIN_VALUE_see|trigger=button|text=}{sub-section}{div:class=sIndent}{sub-section:MIN_VALUE_see|trigger=none}{sub-section}[String] -- A string representing the number in exponential notation.{div}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=link}{tr:id=sam}{td}*External linksSample*\\{sub-section:MIN_VALUE_link|trigger=button|text=}{sub-section}{div:class=sIndent}{sub-section:MIN_VALUE_link|trigger=none}{sub-sectioncode:language=javascript}
var n = 123.45678;
application.output(n.toExponential(3));
{code}{div}{td}{tr}{builder-show}{tr:idclass=samlastDetailRow}{td}*Sample*\\{sub-section:MIN_VALUE_sam|trigger=button|text=}{sub-section}{div:class=sIndent}{sub-section:MIN_VALUE_sam|trigger=none}{code:language=javascript}
application.output("Smallest number: " + Number.MIN_VALUE);
{code}{sub-section}{div}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=NEGATIVE_INFINITY|class=node{td}{tr}{tbody}{tbody:id=toExponential-Number}{tr:id=name}{td}h6.toExponential{td}{tr}{tr:id=sig}{td}{span:style=margin-right: 5px;}[String]{span}{span:style=font-weight: bold;}toExponential{span}{span}\(fractionDigits){span}{td}{tr}{tr:id=nameprs}{td}h6.NEGATIVE_INFINITY{td}{tr}{builder-show:permission=edit}{tr:id=des}{td}{sub-section:NEGATIVE_INFINITY_des|trigger=button|text=}{sub-section}{sub-section:NEGATIVE_INFINITY_des|trigger=none|class=sIndent}Replace with description{sub-section}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=snc}{td}*Since*\\{sub-section:NEGATIVE_INFINITY_snc|trigger=button|text=}{sub-section}{sub-section:NEGATIVE_INFINITY_snc|trigger=none|class=sIndent} Replace with version info{sub-section}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=prs}{td}*Parameters*\\{sub-section:NEGATIVE_INFINITY_prs|trigger=button|text=}{sub-section}{sub-section:NEGATIVE_INFINITY_prs|trigger=none|class=sIndent}{sub-section}{td}{tr}{builder-show}{tr:id=ret}{td}*Returns*\\{sub-section:NEGATIVE_INFINITY_ret|trigger=button|text=}{sub-section}{sub-section:NEGATIVE_INFINITY_ret|trigger=none|class=sIndent}[Number]{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=see}{td}*Also see*\\{sub-section:NEGATIVE_INFINITY_see|trigger=button|text=}{sub-section}{div:class=sIndent}{sub-section:NEGATIVE_INFINITY_see|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=link}{td}*External links*\\{sub-section:NEGATIVE_INFINITY_link|trigger=button|text=}{sub-section}{div:class=sIndent}{sub-section:NEGATIVE_INFINITY_link|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{tr:id=sam}{td}*Sample*\\{sub-section:NEGATIVE_INFINITY_sam|trigger=button|text=}{sub-section}{div:class=sIndent}{sub-section:NEGATIVE_INFINITY_sam|trigger=none}{code:language=javascript}
application.output("Negative infinity: " + Number.NEGATIVE_INFINITY);
{code}{sub-section}{div}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=NaN|class=node}{tr:id=name}{td}h6.NaN{td}{tr}{builder-show:permission=edit}{tr:id=des}{td}{sub-section:NaN_des|trigger=button|text=}{sub-section}{sub-section:NaN_des|trigger=none|class=sIndent}Replace with description{sub-section}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=snc}{td}*Since*\\{sub-section:NaN_snc|trigger=button|text=}{sub-section}{sub-section:NaN_snc|trigger=none|class=sIndent} Replace with version info{sub-section}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=prs}{td}*Parameters*\\{sub-section:NaN_prs|trigger=button|text=}{sub-section}{sub-section:NaN_prs|trigger=none|class=sIndent}{sub-section}{td}{tr}{builder-show}{tr:id=ret}{td}*Returns*\\{sub-section:NaN_ret|trigger=button|text=}{sub-section}{sub-section:NaN_ret|trigger=none|class=sIndent}[Object]{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=see}{td}*Also see*\\{sub-section:NaN_see|trigger=button|text=}{sub-section}{div:class=sIndent}{sub-section:NaN_see|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=link}{td}*External links*\\{sub-section:NaN_link|trigger=button|text=}{sub-section}{div:class=sIndent}{sub-section:NaN_link|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{tr:id=sam}{td}*Sample*\\{sub-section:NaN_sam|trigger=button|text=}{sub-section}{div:class=sIndent}{sub-section:NaN_sam|trigger=none}{code:language=javascript}
application.output("NaN: " + Number.NaN);
{code}{sub-section}{div}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=POSITIVE_INFINITY|class=node}{tr:id=name}{td}h6.POSITIVE_INFINITY{td}{tr}{builder-show:permission=edit}{tr:id=des}{td}{sub-section:POSITIVE_INFINITY_des|trigger=button|text=}{sub-section}{sub-section:POSITIVE_INFINITY_des|trigger=none|class=sIndent}Replace with description{sub-section}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=snc}{td}*Since*\\{sub-section:POSITIVE_INFINITY_snc|trigger=button|text=}{sub-section}{sub-section:POSITIVE_INFINITY_snc|trigger=none|class=sIndent} Replace with version info{sub-section}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=prs}{td}*Parameters*\\{sub-section:POSITIVE_INFINITY_prs|trigger=button|text=}{sub-section}{sub-section:POSITIVE_INFINITY_prs|trigger=none|class=sIndent}{sub-section}{td}{tr}{builder-show}{tr:id=ret}{td}*Returns*\\{sub-section:POSITIVE_INFINITY_ret|trigger=button|text=}{sub-section}{sub-section:POSITIVE_INFINITY_ret|trigger=none|class=sIndent}[Number]{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=see}{td}*Also see*\\{sub-section:POSITIVE_INFINITY_see|trigger=button|text=}{sub-section}{div:class=sIndent}{sub-section:POSITIVE_INFINITY_see|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=link}{td}*External links*\\{sub-section:POSITIVE_INFINITY_link|trigger=button|text=}{sub-section}{div:class=sIndent}{sub-section:POSITIVE_INFINITY_link|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{tr:id=sam}{td}*Sample*\\{sub-section:POSITIVE_INFINITY_sam|trigger=button|text=}{sub-section}{div:class=sIndent}{sub-section:POSITIVE_INFINITY_sam|trigger=none}{code:language=javascript}
application.output("Positive infinity: " + Number.POSITIVE_INFINITY);
{code}{sub-section}{div}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{table}\\ 

{table:id=function|class=servoy sDetail}{colgroup}{column:width=100%|padding=0px}{column}{colgroup}{tr:style=height: 30px;}{th:colspan=1}Method Details{th}{tr}{tbody:id=toExponential|class=node}{tr:id=name}{td}h6.toExponential{td}{tr}{tr:id=sig}{td}{span:style=float: left; margin-right: 5px;}[String]{span}{span:id=iets|style=float: left; font-weight: bold;}toExponential{span}{span:id=iets|style=float: left;}\(){span}{td}{tr}{builder-show:permission=edit}{tr:id=des}{td}{sub-section:toExponential_des|trigger=button|text=}{sub-section}{sub-section:toExponential_des|trigger=none|class=sIndent}Replace with description{sub-section}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=snc}{td}*Since*\\{sub-section:toExponential_snc|trigger=button|text=}{sub-section}{sub-section:toExponential_snc|trigger=none|class=sIndent} Replace with version info{sub-section}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=prs}{td}*Parameters*\\{sub-section:toExponential_prs|trigger=button|text=}{sub-section}{sub-section:toExponential_prs|trigger=none|class=sIndent}{sub-section}{td}{tr}{builder-show}{tr:id=ret}{td}*Returns*\\{sub-section:toExponential_ret|trigger=button|text=}{sub-section}{sub-section:toExponential_ret|trigger=none|class=sIndent}[String] -- A string representing the number in exponential notation.{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=see}{td}*Also see*\\{sub-section:toExponential_see|trigger=button|text=}{sub-section}{div:class=sIndent}{sub-section:toExponential_see|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=link}{td}*External links*\\{sub-section:toExponential_link|trigger=button|text=}{sub-section}{div:class=sIndent}{sub-section:toExponential_link|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{tr:id=sam}{td}*Sample*\\{sub-section:toExponential_sam|trigger=button|text=}{sub-section}{div:class=sIndent}{sub-section:toExponential_sam|trigger=none}{code:language=javascript}
var n = 123.45678;
application.output(n.toExponential(3));
{code}{sub-section}{div}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=toExponential-Number|class=node}{tr:id=name}{td}h6.toExponential{td}{tr}{tr:id=sig}{td}{span:style=float: left; margin-right: 5px;}[String]{span}{span:id=iets|style=float: left; font-weight: bold;}toExponential{span}{span:id=iets|style=float: left;}\(fractionDigits){span}{td}{tr}{builder-show:permission=edit}{tr:id=des}{td}{sub-section:toExponential-Number_des|trigger=button|text=}{sub-section}{sub-section:toExponential-Number_des|trigger=none|class=sIndent}Replace with description{sub-section}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=snc}{td}*Since*\\{sub-section:toExponential-Number_snc|trigger=button|text=}{sub-section}{sub-section:toExponential-Number_snc|trigger=none|class=sIndent} Replace with version info{sub-section}{td}{tr}{builder-show}{tr:id=prs}{td}*Parameters*\\{sub-section:toExponential-Number_prs|trigger=button|text=}{sub-section}{sub-section:toExponential-Number_prs|trigger=none|class=sIndent}\{[Number]} fractionDigits -- An integer specifying the number of digits after the decimal point. Defaults to as many digits as necessary to specify the number.
{sub-section}{td}{tr}{tr:id=ret}{td}*Returns*\\{sub-section:toExponential-Number_ret|trigger=button|text=}{sub-section}{sub-section:toExponential-Number_ret|trigger=none|class=sIndent}[String] -- A string representing the number in exponential notation.{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=see}{td}*Also see*\\{sub-section:toExponential-Number_see|trigger=button|text=}{sub-section}{div:class=sIndent}{sub-section:toExponential-Number_see|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=link}{td}*External links*\\{sub-section:toExponential-Number_link|trigger=button|text=}{sub-section}{div:class=sIndent}{sub-section:toExponential-Number_link|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{tr:id=sam}{td}*Sample*\\{sub-section:toExponential-Number_sam|trigger=button|text=}{sub-section}{div:class=sIndent}{sub-section:toExponential-Number_sam|trigger=none}{code:language=javascript}
var n = 123.45678;
application.output(n.toExponential(3));
{code}{sub-section}{div}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=toFixed|class=node}{tr:id=name}{td}h6.toFixed{td}{tr}{tr:id=sig}{td}{span:style=float: left; margin-right: 5px;}[String]{span}{span:id=iets|style=float: left; font-weight: bold;}toFixed{span}{span:id=iets|style=float: left;}\(){span}{td}{tr}{builder-show:permission=edit}{tr:id=des}{td}{sub-section:toFixed_des|trigger=button|text=}{sub-section}{sub-section:toFixed_des|trigger=none|class=sIndent}Replace with description{sub-section}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=snc}{td}*Since*\\{sub-section:toFixed_snc|trigger=button|text=}{sub-section}{sub-section:toFixed_snc|trigger=none|class=sIndent} Replace with version info{sub-section}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=prs}{td}*Parameters*\\{sub-section:toFixed_prs|trigger=button|text=}{sub-section}{sub-section:toFixed_prs|trigger=none|class=sIndent}{sub-section}{td}{tr}{builder-show}{tr:id=ret}{td}*Returns*\\{sub-section:toFixed_ret|trigger=button|text=}{sub-section}{sub-section:toFixed_ret|trigger=none|class=sIndent}[String] -- A string representing the number in fixed-point notation.{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=see}{td}*Also see*\\{sub-section:toFixed_see|trigger=button|text=}{sub-section}{div:class=sIndent}{sub-section:toFixed_see|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=link}{td}*External links*\\{sub-section:toFixed_link|trigger=button|text=}{sub-section}{div:class=sIndent}{sub-section:toFixed_link|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{tr:id=sam}{td}*Sample*\\{sub-section:toFixed_sam|trigger=button|text=}{sub-section}{div:class=sIndent}{sub-section:toFixed_sam|trigger=none}{code:language=javascript}
var n = 123.45678;
application.output(n.toFixed(3));
{code}{sub-section}{div}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=toFixed-Number|class=node}{tr:id=name}{td}h6.toFixed{td}{tr}{tr:id=sig}{td}{span:style=float: left; margin-right: 5px;}[String]{span}{span:id=iets|style=float: left; font-weight: bold;}toFixed{span}{span:id=iets|style=float: left;}\(digits){span}{td}{tr}{builder-show:permission=edit}{tr:id=des}{td}{sub-section:toFixed-Number_des|trigger=button|text=}{sub-section}{sub-section:toFixed-Number_des|trigger=none|class=sIndent}Replace with description{sub-section}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=snc}{td}*Since*\\{sub-section:toFixed-Number_snc|trigger=button|text=}{sub-section}{sub-section:toFixed-Number_snc|trigger=none|class=sIndent} Replace with version info{sub-section}{td}{tr}{builder-show}{tr:id=prs}{td}*Parameters*\\{sub-section:toFixed-Number_prs|trigger=button|text=}{sub-section}{sub-section:toFixed-Number_prs|trigger=none|class=sIndent}\{[Number]} digits -- The number of digits to appear after the decimal point. Defaults to 0.
{sub-section}{td}{tr}{tr:id=ret}{td}*Returns*\\{sub-section:toFixed-Number_ret|trigger=button|text=}{sub-section}{sub-section:toFixed-Number_ret|trigger=none|class=sIndent}[String] -- A string representing the number in fixed-point notation.{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=see}{td}*Also see*\\{sub-section:toFixed-Number_see|trigger=button|text=}{sub-section}{div:class=sIndent}{sub-section:toFixed-Number_see|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=link}{td}*External links*\\{sub-section:toFixed-Number_link|trigger=button|text=}{sub-section}{div:class=sIndent}{sub-section:toFixed-Number_link|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{tr:id=sam}{td}*Sample*\\{sub-section:toFixed-Number_sam|trigger=button|text=}{sub-section}{div:class=sIndent}{sub-section:toFixed-Number_sam|trigger=none}{code:language=javascript}
var n = 123.45678;
application.output(n.toFixed(3));
{code}{sub-section}{div}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=toLocaleString|class=node}{tr:id=name}{td}h6.toLocaleString{td}{tr}{tr:id=sig}{td}{span:style=float: left; margin-right: 5px;}[String]{span}{span:id=iets|style=float: left; font-weight: bold;}toLocaleString{span}{span:id=iets|style=float: left;}\(){span}{td}{tr}{builder-show:permission=edit}{tr:id=des}{td}{sub-section:toLocaleString_des|trigger=button|text=}{sub-section}{sub-section:toLocaleString_des|trigger=none|class=sIndent}Replace with description{sub-section}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=snc}{td}*Since*\\{sub-section:toLocaleString_snc|trigger=button|text=}{sub-section}{sub-section:toLocaleString_snc|trigger=none|class=sIndent} Replace with version info{sub-section}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=prs}{td}*Parameters*\\{sub-section:toLocaleString_prs|trigger=button|text=}{sub-section}{sub-section:toLocaleString_prs|trigger=none|class=sIndent}{sub-section}{td}{tr}{builder-show}{tr:id=ret}{td}*Returns*\\{sub-section:toLocaleString_ret|trigger=button|text=}{sub-section}{sub-section:toLocaleString_ret|trigger=none|class=sIndent}[String] -- A string representing the number in the current locale.{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=see}{td}*Also see*\\{sub-section:toLocaleString_see|trigger=button|text=}{sub-section}{div:class=sIndent}{sub-section:toLocaleString_see|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=link}{td}*External links*\\{sub-section:toLocaleString_link|trigger=button|text=}{sub-section}{div:class=sIndent}{sub-section:toLocaleString_link|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{tr:id=sam}{td}*Sample*\\{sub-section:toLocaleString_sam|trigger=button|text=}{sub-section}{div:class=sIndent}{sub-section:toLocaleString_sam|trigger=none}{code:language=javascript}
var n = 1000000;
application.output(n.toLocaleString());
{code}{sub-section}{div}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=toPrecision|class=node}{tr:id=name}{td}h6.toPrecision{td}{tr}{tr:id=sig}{td}{span:style=float: left; margin-right: 5px;}[String]{span}{span:id=iets|style=float: left; font-weight: bold;}toPrecision{span}{span:id=iets|style=float: left;}\(){span}{td}{tr}{builder-show:permission=edit}{tr:id=des}{td}{sub-section:toPrecision_des|trigger=button|text=}{sub-section}{sub-section:toPrecision_des|trigger=none|class=sIndent}Replace with description{sub-section}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=snc}{td}*Since*\\{sub-section:toPrecision_snc|trigger=button|text=}{sub-section}{sub-section:toPrecision_snc|trigger=none|class=sIndent} Replace with version info{sub-section}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=prs}{td}*Parameters*\\{sub-section:toPrecision_prs|trigger=button|text=}{sub-section}{sub-section:toPrecision_prs|trigger=none|class=sIndent}{sub-section}{td}{tr}{builder-show}{tr:id=ret}{td}*Returns*\\{sub-section:toPrecision_ret|trigger=button|text=}{sub-section}{sub-section:toPrecision_ret|trigger=none|class=sIndent}[String] -- A string representing the number to a specified precision in fixed-point or exponential notation.{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=see}{td}*Also see*\\{sub-section:toPrecision_see|trigger=button|text=}{sub-section}{div:class=sIndent}{sub-section:toPrecision_see|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=link}{td}*External links*\\{sub-section:toPrecision_link|trigger=button|text=}{sub-section}{div:class=sIndent}{sub-section:toPrecision_link|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{tr:id=sam}{td}*Sample*\\{sub-section:toPrecision_sam|trigger=button|text=}{sub-section}{div:class=sIndent}{sub-section:toPrecision_sam|trigger=none}{code:language=javascript}
var n = 123.45678;
application.output(n.toPrecision(5));
{code}{sub-section}{div*Parameters*\\{div:class=sIndent}\{[Number]} fractionDigits -- An integer specifying the number of digits after the decimal point. Defaults to as many digits as necessary to specify the number.
{div}{td}{tr}{tr:id=ret}{td}*Returns*\\{div:class=sIndent}[String] -- A string representing the number in exponential notation.{div}{td}{tr}{tr:id=sam}{td}*Sample*\\{div:class=sIndent}{code:language=javascript}
var n = 123.45678;
application.output(n.toExponential(3));
{code}{div}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=toFixed}{tr:id=name}{td}h6.toFixed{td}{tr}{tr:id=sig}{td}{span:style=margin-right: 5px;}[String]{span}{span:style=font-weight: bold;}toFixed{span}{span}\(){span}{td}{tr}{tr:classid=lastDetailRowret}{td}{td}{tr}{tbody}{tbody:id=toPrecision-Number|class=node}{tr:id=name}{td}h6.toPrecision*Returns*\\{div:class=sIndent}[String] -- A string representing the number in fixed-point notation.{div}{td}{tr}{tr:id=sigsam}{td}*Sample*\\{spandiv:style=float: left; margin-right: 5px;}[String]{span}{span:id=iets|style=float: left; font-weight: bold;}toPrecision{span}{span:id=iets|style=float: left;}\(precision){spanclass=sIndent}{code:language=javascript}
var n = 123.45678;
application.output(n.toFixed(3));
{code}{div}{td}{tr}{builder-showtr:permissionclass=editlastDetailRow}{tr:id=destd}{td}{sub-section:toPrecision-Number_des|trigger=button|text=}{sub-section}{sub-section:toPrecision-Number_des|trigger=none|class=sIndent}Replace with description{sub-section}{td}{tr}{builder-show}{builder-show:permission=edittr}{tbody}{tbody:id=toFixed-Number}{tr:id=name}{td}h6.toFixed{td}{tr}{tr:id=sncsig}{td}*Since*\\{sub-section:toPrecision-Number_snc|trigger=button|text=}{sub-section}{sub-section:toPrecision-Number_snc|trigger=none|class=sIndent} Replace with version info{sub-section{span:style=margin-right: 5px;}[String]{span}{span:style=font-weight: bold;}toFixed{span}{span}\(digits){span}{td}{tr}{builder-show}{tr:id=prs}{td}*Parameters*\\{sub-section:toPrecision-Number_prs|trigger=button|text=}{sub-section}{sub-section:toPrecision-Number_prs|trigger=none|div:class=sIndent}\{[Number]} precisiondigits -- An integer specifying The number of digits to appear after the number of significant digitsdecimal point. Defaults to 0.
{sub-sectiondiv}{td}{tr}{tr:id=ret}{td}*Returns*\\{sub-section:toPrecision-Number_ret|trigger=button|text=}{sub-section}{sub-section:toPrecision-Number_ret|trigger=none|div:class=sIndent}[String] -- A string representing the number to a specified precision in fixed-point or exponential notation.{sub-section number in fixed-point notation.{div}{td}{tr}{tr:id=sam}{td}*Sample*\\{div:class=sIndent}{code:language=javascript}
var n = 123.45678;
application.output(n.toFixed(3));
{code}{div}{td}{tr}{builder-showtr:permissionclass=editlastDetailRow}{tr:id=seetd}{td}*Also see*\\{sub-section:toPrecision-Number_see|trigger=button|text=}{sub-section}{div:class=sIndent}{sub-section:toPrecision-Number_see|trigger=none}{sub-section}{div}{tr}{tbody}{tbody:id=toLocaleString}{tr:id=name}{td}h6.toLocaleString{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=linksig}{td}*External links*\\{sub-section:toPrecision-Number_link|trigger=button|text=}{sub-section}{div:class=sIndent}{sub-section:toPrecision-Number_link|trigger=none}{sub-section}{div{span:style=margin-right: 5px;}[String]{span}{span:style=font-weight: bold;}toLocaleString{span}{span}\(){span}{td}{tr}{builder-show}{tr:id=samret}{td}*SampleReturns*\\{sub-section:toPrecision-Number_sam|trigger=button|text=}{sub-section}div:class=sIndent}[String] -- A string representing the number in the current locale.{div}{td}{tr}{tr:id=sam}{td}*Sample*\\{div:class=sIndent}{sub-section:toPrecision-Number_sam|trigger=none}{code:language=javascript}
var n = 123.456781000000;
application.output(n.toPrecision(5));
{code}{sub-section}{div}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=toString|class=node}{tr:id=name}{td}h6.toStringtoLocaleString());
{code}{div}{td}{tr}{tr:id=sigclass=lastDetailRow}{td}{td}{span:style=float: left; margin-right: 5px;}[String]{span}{span:id=iets|style=float: left; font-weight: bold;}toString{span}{span:id=iets|style=float: left;}\(){span}tr}{tbody}{tbody:id=toPrecision}{tr:id=name}{td}h6.toPrecision{td}{tr}{builder-show:permission=edit}{tr:id=dessig}{td}{sub-section:toString_des|trigger=button|text=}{sub-section}{sub-section:toString_des|trigger=none|class=sIndent}Replace with description{sub-sectionspan:style=margin-right: 5px;}[String]{span}{span:style=font-weight: bold;}toPrecision{span}{span}\(){span}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=sncret}{td}*SinceReturns*\\{sub-section:toString_snc|trigger=button|text=}{sub-section}{sub-section:toString_snc|trigger=none|class=sIndent} Replace with version info{sub-sectiondiv:class=sIndent}[String] -- A string representing the number to a specified precision in fixed-point or exponential notation.{div}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=prssam}{td}*ParametersSample*\\{sub-section:toString_prs|trigger=button|text=}{sub-section}{sub-section:toString_prs|trigger=none|class=sIndent}{sub-sectiondiv:class=sIndent}{code:language=javascript}
var n = 123.45678;
application.output(n.toPrecision(5));
{code}{div}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{builder-showtbody:id=toPrecision-Number}{tr:id=ret}name}{td}h6.toPrecision{td}*Returns*\\{sub-section:toString_ret|trigger=button|text=}{sub-section}{sub-section:toString_ret|trigger=none|class=sIndent}[String] -- A string representing the specified Number object.{sub-section}{tr}{tr:id=sig}{td}{span:style=margin-right: 5px;}[String]{span}{span:style=font-weight: bold;}toPrecision{span}{span}\(precision){span}{td}{tr}{builder-show:permission=edit}{tr:id=seeprs}{td}*Also seeParameters*\\{sub-section:toString_see|trigger=button|text=}{sub-section}{div:class=sIndent}{sub-section:toString_see|trigger=none}{sub-section}\{[Number]} precision -- An integer specifying the number of significant digits.
{div}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=linkret}{td}*External linksReturns*\\{sub-section:toString_link|trigger=button|text=}{sub-section}{div:class=sIndent}{sub-section:toString_link|trigger=none}{sub-section}[String] -- A string representing the number to a specified precision in fixed-point or exponential notation.{div}{td}{tr}{builder-show}{tr:id=sam}{td}*Sample*\\{sub-section:toString_sam|trigger=button|text=}{sub-section}{div:class=sIndent}{sub-section:toString_sam|trigger=none}{code:language=javascript}
var n = 7;
application.output(n.toString()); //displays "7" 123.45678;
application.output(n.toStringtoPrecision(25)); //displays
"111"
{code}{sub-section}{div}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=toString-Number|class=node}{tr:id=name}{td}h6.toString{td}{tr}{tr:id=sig}{td}{span:style=float: left; margin-right: 5px;}[String]{span}{span:id=iets|style=float: left; font-weight: bold;}toString{span}{span:id=iets|style=float: left;}\(radix){span}tr}{tbody}{tbody:id=toString}{tr:id=name}{td}h6.toString{td}{tr}{builder-show:permission=edit}{tr:id=dessig}{td}{sub-section:toString-Number_des|trigger=button|text=}{sub-section}{sub-section:toString-Number_des|trigger=none|class=sIndent}Replace with description{sub-section}{td}{tr}{builder-show}{builder-show:permission=editspan:style=margin-right: 5px;}[String]{span}{span:style=font-weight: bold;}toString{span}{span}\(){span}{td}{tr}{tr:id=sncret}{td}*SinceReturns*\\{sub-section:toString-Number_snc|trigger=button|text=}{sub-section}{sub-section:toString-Number_snc|trigger=none|{div:class=sIndent} Replace with version info{sub-section[String] -- A string representing the specified Number object.{div}{td}{tr}{builder-show}{tr:id=prssam}{td}*ParametersSample*\\{sub-section:toString-Number_prs|trigger=button|text=}{sub-section}{sub-section:toString-Number_prs|trigger=none|div:class=sIndent}\{[Number]{code:language=javascript}
radixvar --n An= integer between 2 and 36 specifying the base to use for representing numeric values
{sub-section7;
application.output(n.toString()); //displays "7"
application.output(n.toString(2)); //displays "111"
{code}{div}{td}{tr}{tr:class=lastDetailRow}{td}{trtd}{tr:id=ret}{tdtbody}*Returns*\\{sub-section:{tbody:id=toString-Number_ret|trigger=button|text=}{sub-section}{sub-section:toString-Number_ret|trigger=none|class=sIndent}[String] -- A string representing the specified Number object.{sub-section}}{tr:id=name}{td}h6.toString{td}{tr}{builder-show:permission=edit}{tr:id=seesig}{td}*Also see*\\{sub-section:toString-Number_see|trigger=button|text=}{sub-section}{div:class=sIndent}{sub-section:toString-Number_see|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{builder-show:permission=edit{span:style=margin-right: 5px;}[String]{span}{span:style=font-weight: bold;}toString{span}{span}\(radix){span}{td}{tr}{tr:id=linkprs}{td}*External linksParameters*\\{sub-section:toString-Number_link|trigger=button|text=}{sub-section}div:class=sIndent}\{[Number]} radix -- An integer between 2 and 36 specifying the base to use for representing numeric values
{div}{td}{tr}{tr:id=ret}{td}*Returns*\\{div:class=sIndent}{sub-section:toString-Number_link|trigger=none}{sub-section}{[String] -- A string representing the specified Number object.{div}{td}{tr}{builder-show}{tr:id=sam}{td}*Sample*\\{sub-section:toString-Number_sam|trigger=button|text=}{sub-section}{div:class=sIndent}{sub-section:toString-Number_sam|trigger=none}{code:language=javascript}
var n = 7;
application.output(n.toString()); //displays "7"
application.output(n.toString(2)); //displays "111"
{code}{sub-section}{div}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{table}