Home > SharePoint, SharePoint 2010, SP2010 > The Type or namespace name “DateTimeControl” does not exist in the namespace “Microsoft.SharePoint.WebControls”

The Type or namespace name “DateTimeControl” does not exist in the namespace “Microsoft.SharePoint.WebControls”

If you create an empty SharePoint 2010 project in Visual Studio 2010 and then add a visual Web Part (Sandboxed) you will get an error when you try to debug.

The Type or namespace name “DateTimeControl” does not exist in the namespace “Microsoft.SharePoint.WebControls”


However you can add the DateTimeControl to a farm solution visual web part.

  1. June 10, 2013 at 19:17

    Thanks. I couldn’t find this answer anywhere else. BTW: I’m using 2013 and there’s still the same error and the same fix.

  1. No trackbacks yet.

Leave a comment

Design a site like this with WordPress.com
Get started