CultureInfo culture = new CultureInfo("en-AU");The example above reads the DateTime variable in using the Australian format (dd/mm/yyyy). It comes in useful if the control is set to display US format for example.
DateTime reportDate = DateTime.Parse(txtDate.Text, culture);
No comments:
Post a Comment