Fixing a Date Formatting Bug in ASP.NET 2.0

Sometime between beta 2 and beta 3, a bug crept into ASP.NET 2.0’s BoundField class that prevents date formatting from working. In the following declaration, the “{0:d”} is ignored:

The bug was slated to be fixed in the RTM release, but alas, it wasn’t. There is, however, a work-around: set the BoundField’s HtmlEncode property to false:

<asp:BoundField HtmlEncode=”false” … />

Microsoft is aware of the bug and has promised that it will be fixed in a future release.

We deliver solutions that accelerate the value of Azure.

Ready to experience the full power of Microsoft Azure?

Start Today

Blog Home

Stay Connected

Upcoming Events

All Events