DateTime
is irespective of the format, format is only for displaying purpose. If you are not getting the right date in wrongformat
then you can use DateTime.ParseExact
with the format. and then simply
txt_actualrightformat.Text = wrongformat.ToString("dd/MM/yyyy");
EDIT:
use DateTime.ParseExcat
like:
DateTime dt = DateTime.ParseExact(TextBox4.Text, "MM/dd/yyyy", CultureInfo.InvariantCulture);
txt_actualrightformat = dt.ToString("dd/MM/yyyy");