2013-01-15 1 views
0

난은 SharePoint를 구현 한 : DateTimeControl를 매우 간단한는 WebPart에서셰어 : SP2013에 DateTimeControl 충돌는 WebPart

<SharePoint:DateTimeControl ID="dtStartdate" runat="server" DateOnly="true" /> 

나는 그것이 예외

Server Error in '/' Application. 
Object reference not set to an instance of an object. 

Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code. 
Exception Details: System.NullReferenceException: Object reference not set to an instance of an object. 

Source Error: 
An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below. 

Stack Trace: 
[NullReferenceException: Object reference not set to an instance of an object.] 
    Microsoft.SharePoint.Utilities.SPUtility.GetThemedImageUrl(String originalUrl, String themeKey) +199 
    Microsoft.SharePoint.WebControls.DatePicker..ctor() +1460 
    Microsoft.SharePoint.WebControls.SPDatePickerControl.InitDatePicker() +44 
    Microsoft.SharePoint.WebControls.SPDatePickerControl.set_MinJDay(Int32 value) +25 
    Microsoft.SharePoint.ApplicationPages.DatePickerFrame.Page_Load(Object sender, EventArgs e) +1708 
    System.EventHandler.Invoke(Object sender, EventArgs e) +0 
    System.Web.UI.Control.LoadRecursive() +94 
    System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +2935 

Version Information: Microsoft .NET Framework Version:4.0.30319; ASP.NET Version:4.0.30319.17929

enter image description here을 렌더링하는 컨트롤을 클릭 할 때 문제는

이 문제를 해결하는 데 필요한 조언이나 도움은 매우 감사합니다.

답변

1

나는 당신이 이것을 물어봤을 때부터 매우 비슷한 것을 해결했지만 내 (단순한) 솔루션을 공유 할 것이라고 생각했습니다.

웹 응용 프로그램의 루트에 사이트 모음이 만들어 졌는지 확인하십시오.

http : // webapp/sites/mysitecollection에서 웹 파트에서 작업 중이며 위의 오류가있었습니다. http : // webapp를 보면 404가 나왔기 때문에 루트 사이트 모음을 만들었고 이제는 sitecollection의 datepicker가 제대로 작동합니다.