string formatted = date.ToString("dd-MM-yyyy");
will do it.
Here is a good reference for different formats.
More Related Contents:
- How do I get the AM/PM value from a DateTime?
- Convert DateTime to a specified Format
- .NET: Why is TryParseExact failing on Hmm and Hmmss?
- DateTime vs DateTimeOffset
- Nullable types and the ternary operator: why is `? 10 : null` forbidden? [duplicate]
- C# string replace does not actually replace the value in the string [duplicate]
- How do I decompile a .NET EXE into readable C# source code?
- How is Math.Pow() implemented in .NET Framework?
- How to find the Number of CPU Cores via .NET/C#?
- Any decent C# profilers out there? [closed]
- Getting the application’s directory from a WPF application
- C# – approach for saving user settings in a WPF application?
- how to implement url rewriting similar to SO
- C# – Fill a combo box with a DataTable
- Recursive List Flattening
- Convert from BitArray to Byte
- Why does this simple .NET console app have so many threads?
- ASP.NET MVC Razor render without encoding
- Why is Main method private?
- Does the Enumerator of a Dictionary return key value pairs in the order they were added?
- When should I use out parameters?
- Error – is not marked as serializable
- EWS – Access All Shared Calendars
- ArrayList vs List
- DateTime.Parse(“2012-09-30T23:00:00.0000000Z”) always converts to DateTimeKind.Local
- Set Item Focus in ListView WPF
- Get types used inside a C# method body
- Accessing static fields in XAML
- How to get only filenames within a directory using c#?
- Why does WPF databinding swallow exceptions?