Hexapp Documentation
Hexapp Documentation
Hexapp API
Reference
Packflow.Interface
PFDateTimeExtensions Class
PFDateTimeExtensions Methods
GetNaturalDate Method
GetNaturalDate Method (DateTime, PFTranslations)
GetNaturalDate Method (DateTimeOffset, PFTranslations)
GetNaturalDate Method (DateTime, PFTranslations, RelativeTimeResolution)
GetNaturalDate Method (DateTimeOffset, PFTranslations, RelativeTimeResolution)
PFDateTimeExtensions
GetNaturalDate Method (DateTime, PFTranslations)
Expresses the time difference between the given
DateTime
and the current time in a user-friendly translated text. E.g. "9 weeks ago".
Namespace:
Packflow.Interface
Assembly:
MicaSystems.Packflow.Interface (in MicaSystems.Packflow.Interface.dll) Version: 1.0.0.0 (2.0.0.223)
Syntax
C#
Copy
public
static
string
GetNaturalDate
(
this
DateTime
date
,
PFTranslations
translations
)
Parameters
date
Type:
System
DateTime
The relative
DateTime
.
translations
Type:
Packflow.Interface
PFTranslations
Object providing translations used to generate the expected text.
Return Value
Type:
String
A text representing the time difference.
Usage Note
In Visual Basic and C#, you can call this method as an instance method on any object of type
DateTime
. When you use instance method syntax to call this method, omit the first parameter. For more information, see
Extension Methods (Visual Basic)
or
Extension Methods (C# Programming Guide)
.
See Also
Reference
PFDateTimeExtensions Class
GetNaturalDate Overload
Packflow.Interface Namespace
www.hexapp.com
×
Close feedback form
Send us
comments or requests about documentation