Sep 24, 2014, 9:22 PM
Missing time value in DateField
Hello,
I have an <ext:Toolbar> with a DateField and a button:
Any suggestion to get the time portion correctly?
Thank you
Regards
Alex
I have an <ext:Toolbar> with a DateField and a button:
<ext:DateField ID="dtDesde" runat="server" Format="dd/MM/yyyy HH:mm" Width="125" />
<ext:Button ID="Button1" runat="server" Text="Filtrar" Icon="DatabaseGo" OnDirectClick="Buscar_Evento" />
When button is clicked, code-behind function Buscar_Evento is fired:protected void Buscar_Evento(object sender, EventArgs e)
{
DateTime fechaDesde = (DateTime)dtDesde.Value;
}
The problem is that, even when the dtDesde DateField control shows '24/09/2014 14:19' on the page, when the code-behind is invoked, dtDesde.Value has '24/09/2014 0:00:00' as value and time portion is lost.Any suggestion to get the time portion correctly?
Thank you
Regards
Alex