alex of How To
11/19/2014 - 9:07 PM

HTML5 Input Type Date - Specifying Default Value For a Date Picker

HTML5 Input Type Date - Specifying Default Value For a Date Picker

Dim dAnyDate As Date
Dim sHTML5DateInputTypeFormatedString As String 

'Keeping it simple here 
sHTML5DateInputTypeFormatedString = dAnyDate.ToString("yyyy-MM-dd")

'You have to format it this way (YYYY-MM-DD) to specify the default 
<input type="date" value="@sHTML5DateInputTypeFormatedString">