A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://learn.microsoft.com/en-us/dotnet/api/system.formattablestring.invariant below:

FormattableString.Invariant(FormattableString) Method (System) | Microsoft Learn

FormattableString.Invariant(FormattableString) Method Definition

Returns a result string in which arguments are formatted by using the conventions of the invariant culture.

public:
 static System::String ^ Invariant(FormattableString ^ formattable);
public static string Invariant(FormattableString formattable);
static member Invariant : FormattableString -> string
Public Shared Function Invariant (formattable As FormattableString) As String
Parameters Returns

The string that results from formatting the current instance by using the conventions of the invariant culture.

Exceptions Remarks

This static method can be imported in C# by the following statement:

using static System.FormattableString;  

Within the scope that using static directive, an interpolated string may be formatted using the conventions of the invariant culture by code such as the following:

Invariant($"{{ lat = {latitude}; lon = {longitude} }}")   

Collaborate with us on GitHub

The source for this content can be found on GitHub, where you can also create and review issues and pull requests. For more information, see our contributor guide. In this article

Was this page helpful?


RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4