Språk

NumberPrototype.toFixed(Object, Double) Metod

Definition

Skapar en strängrepresentation av den angivna NumberObject som visar det angivna antalet decimalsiffror.

Detta API stöder produktinfrastrukturen och är inte avsett att användas direkt från koden.

public:
 static System::String ^ toFixed(System::Object ^ thisob, double fractionDigits);
[Microsoft.JScript.JSFunction(Microsoft.JScript.JSFunctionAttributeEnum.HasThisObject, Microsoft.JScript.JSBuiltin.Number_toFixed)]
public static string toFixed(object thisob, double fractionDigits);
[<Microsoft.JScript.JSFunction(Microsoft.JScript.JSFunctionAttributeEnum.HasThisObject, Microsoft.JScript.JSBuiltin.Number_toFixed)>]
static member toFixed : obj * double -> string
Public Shared Function toFixed (thisob As Object, fractionDigits As Double) As String

Parametrar

thisob
Object

Det objekt som den här metoden agerar på.

fractionDigits
Double

Ett tal mellan 0 och 20 som representerar antalet decimaler som ska visas. Standardvärdet är 0.

Returer

En strängrepresentation av thisob.

Attribut

Gäller för

Se även