SharePoint DateTime control not loading for some user (DateTimeControl Access denied )

It is a permission issue.
 
DateTimeControl field uses the iframe calender page to render the actual calender. The location of iframe.aspx is C:\Program Files\Common Files\Microsoft Shared\Web Server Extensions\14\TEMPLATE\LAYOUTS
The problem appeared to be with managed paths in the site collections, the Users with “Contribute access” were accessing the following path:
http://myserver/_layouts/iframe.aspx (Path to Root site collection where user doesn’t have access)
 
 
The solution:

DateTimeControl .DatePickerFrameUrl =SPContext.Current.Web.Url+”/_layouts/iframe.aspx “;
Or
DatePickerFrameUrl = “” DateOnly=”true” runat=”server” />
~site/ is an equivalent to SPContext.Current.Web.ServerRelativeUrl
~sitecollection/  is an equivalent to SPContext.Current.Site.ServerRelativeUrl
Advertisements

8 thoughts on “SharePoint DateTime control not loading for some user (DateTimeControl Access denied )

  1. Where should i entry this code ? In my MasterPage or where ?

    DateTimeControl .DatePickerFrameUrl =SPContext.Current.Web.Url+”/_layouts/iframe.aspx “;

    Like

  2. Is it showing for all users? Is this issue for only this site means is your top level site showing correct iFrame?
    It seems to be issue with loading iFrame. Some files used by Calender control are not loading in browser. Can you check with IE developer tool that path for Date iFrame and type the same in browser,

    In SP 2010 it was http:///_layouts/iframe.aspx

    Like

  3. Yes i get this issue by every users and by every site.
    The iFrame path looks as follow iframe.aspx?cal=1&lcid=1031&langid=1031&tz=00%3a59%3a59.9991720&ww=0111110&fdow=1&fwoy=0&hj=0&swn=False&minjday=109207&maxjday=2666269&date=28.11.201

    Like

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s