Exemple #1
0
 /// <summary>
 /// Converts the value of the current System.DateTime object to its equivalent string
 /// representation using the specified format and culture-specific format information.
 /// </summary>
 /// <param name="format">A standard or custom date and time format string..</param>
 /// <param name="provider">An object that supplies culture-specific formatting information.</param>
 /// <returns>
 /// A <see cref="System.String" /> representation of value of the current System.DateTime object as specified by format and provider.
 /// </returns>
 /// <exception cref="System.FormatException">
 /// The length of format is 1, and it is not one of the format specifier characters defined for System.Globalization.DateTimeFormatInfo. -or- format does not contain a valid custom format pattern.
 /// </exception>
 /// <exception cref="System.ArgumentOutOfRangeException">
 /// The date and time is outside the range of dates supported by the calendar used by provider.
 /// </exception>
 public string ToString(string format, IFormatProvider provider)
 {
     return(OriginalDate.ToString(format, provider));
 }
Exemple #2
0
 /// <summary>
 /// Converts the value of the current System.DateTime object to its equivalent string
 ///     representation using the specified format and culture-specific format information.
 /// </summary>
 /// <param name="format">A standard or custom date and time format string..</param>
 /// <returns>
 /// A <see cref="System.String" /> representation of value of the current System.DateTime object as specified by format and provider.
 /// </returns>
 /// <exception cref="System.FormatException">
 /// The length of format is 1, and it is not one of the format specifier characters defined for System.Globalization.DateTimeFormatInfo. -or- format does not contain a valid custom format pattern.
 /// </exception>
 /// <exception cref="System.ArgumentOutOfRangeException">
 /// The date and time is outside the range of dates supported by the calendar used by provider.
 /// </exception>
 public string ToString(string format)
 {
     return(OriginalDate.ToString(format));
 }
Exemple #3
0
 /// <summary>
 ///     Converts the value of the current System.DateTime object to its equivalent string
 ///     representation using the specified format and the formatting conventions of the
 ///     current culture.
 /// </summary>
 /// /// <returns>
 /// A <see cref="System.String" /> representation of value of the current System.DateTime object as specified by format and provider.
 /// </returns>
 /// <exception cref="System.FormatException">
 /// The length of format is 1, and it is not one of the format specifier characters defined for System.Globalization.DateTimeFormatInfo. -or- format does not contain a valid custom format pattern.
 /// </exception>
 /// <exception cref="System.ArgumentOutOfRangeException">
 /// The date and time is outside the range of dates supported by the calendar used by provider.
 /// </exception>
 public override string ToString()
 {
     return(OriginalDate.ToString("d"));
 }
Exemple #4
0
 /// <summary>
 /// Converts the value of the current System.DateTime object to its equivalent string
 ///     representation using the specified format and culture-specific format information.
 /// </summary>
 /// <param name="provider">An object that supplies culture-specific formatting information.</param>
 /// <returns>
 /// A <see cref="System.String" /> representation of value of the current System.DateTime object as specified by format and provider.
 /// </returns>
 /// <exception cref="System.FormatException">
 /// The length of format is 1, and it is not one of the format specifier characters defined for System.Globalization.DateTimeFormatInfo. -or- format does not contain a valid custom format pattern.
 /// </exception>
 /// <exception cref="System.ArgumentOutOfRangeException">
 /// The date and time is outside the range of dates supported by the calendar used by provider.
 /// </exception>
 public string ToString(IFormatProvider provider)
 {
     return(OriginalDate.ToString(provider));
 }