FormattableString.Format Property
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Returns the composite format string.
public:
abstract property System::String ^ Format { System::String ^ get(); };
public abstract string Format { get; }
member this.Format : string
Public MustOverride ReadOnly Property Format As String
Property Value
The composite format string.
Remarks
A composite format string consists of zero or more runs of fixed text intermixed with one or more format items, which are indicated by an index number delimited with brackets (for example, {0}
). The index of each format item corresponds to an argument in an object list that follows the composite format string. For example, in the following statement:
String.Format("Name = {0}, hours = {1:hh}", name, DateTime.Now);
String.Format("Name = {0}, hours = {1:hh}", name, DateTime.Now)
String.Format("Name = {0}, hours = {1:hh}", name, DateTime.Now)
the composite format string is "Name = {0}, hours = {1:hh}"
.
Applies to
See also
Váš názor
https://aka.ms/ContentUserFeedback.
Připravujeme: V průběhu roku 2024 budeme postupně vyřazovat problémy z GitHub coby mechanismus zpětné vazby pro obsah a nahrazovat ho novým systémem zpětné vazby. Další informace naleznete v tématu:Odeslat a zobrazit názory pro