Post Pic

Umbraco DatePicker – Unknown server tag

I have recently needed to use the Umbraco datePicker control in a usercontrol I was creating however I kept getting presented with an “Unknown server tag ‘umbraco:datePicker” exception. After some digging around in the Umbraco Source it is confusingly not in the assembly I would have expected but it was in fact located in the cms.dll and not controls.dll. As a couple of other Umbracians posted this query a day or so after I found the solution I thought I would post it up for the benefit of others.

Simply include the following in your usercontrol:

<%@ Register TagPrefix="umbraco" Namespace="umbraco.controls" Assembly="cms" %>

and then use it as follows:

<umbraco:datePicker ID="datePicker1" runat="server" ShowTime="true"></umbraco:datePicker>

I hope this is of help to others and can be refactored asap to avoid any further confusion.

Umbraco Certified Developer
SagePay Approved Partner
Creative Market