Xceed Toolkit for .NET Maui v2.0 Documentation
Xceed.Maui.Toolkit Assembly / Xceed.Maui.Toolkit Namespace / DateUpDown Class / FormatPattern Property
Example


In This Topic
    FormatPattern Property (DateUpDown)
    In This Topic
    Gets or sets the DateTimeFormatPattern that will be used to display the DateOnly value.  
    Syntax
    'Declaration
     
    
    Public Property FormatPattern As DateFormatPattern
    'Usage
     
    
    Dim instance As DateUpDown
    Dim value As DateFormatPattern
     
    instance.FormatPattern = value
     
    value = instance.FormatPattern
    public DateFormatPattern FormatPattern {get; set;}
    Remarks

    The default value is LongDate.

    Note that when a Custom value is used for this property, it is also necessary to use the CustomFormatString property; this is done in order to set the string that will contain the date symbols.

    You can refer to the example below to see how this can look in your code.

    Example

    The following code would display this control:

    <xctk:DateUpDown WidthRequest="300"
                     FormatPattern="Custom"
                     CustomFormatString=" 'Date is' yyyy/dd/MM"/>
    Requirements

    Target Platforms: Windows 11, Windows 10, Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2

    See Also