i got a string with a datetime value so i want to validate that the value is always with this format "yyyy-MM-ddTHH:mm:ss" how can i do that?
i have this code but it´s always throwing true.
public Boolean validaFecha(string fecha)
{
DateTime dDate;
Boolean resp = false;
if (DateTime.TryParse(fecha, out dDate))
{
resp = true;
}
return resp;
}