+1-888-365-2779
Try Now
More in this section

Forums / Bugs & Issues / exception when accessing admin section

exception when accessing admin section

5 posts, 0 answered
  1. Nick
    Nick avatar
    91 posts
    Registered:
    04 Aug 2008
    10 Sep 2009
    Link to this post
    Hi all,

    Recently the following exception has occured when we attempt to access the admin section of sitefinity.

    the page /Sitefinity/Admin/CmsAdmin/Services.aspx throws the following exception:

    String was not recognized as a valid DateTime.

    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.FormatException: String was not recognized as a valid DateTime.

    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:

    [FormatException: String was not recognized as a valid DateTime.]
       System.DateTimeParse.Parse(String s, DateTimeFormatInfo dtfi, DateTimeStyles styles) +2834318
       Telerik.Cms.Web.UI.DateTimeLiteral.set_Text(String value) +88
       Telerik.Search.WebControls.Admin.ControlPanel.Indexes_ItemDataBound(Object sender, RepeaterItemEventArgs e) +454
       System.Web.UI.WebControls.Repeater.OnItemDataBound(RepeaterItemEventArgs e) +108
       System.Web.UI.WebControls.Repeater.CreateItem(Int32 itemIndex, ListItemType itemType, Boolean dataBind, Object dataItem) +136
       System.Web.UI.WebControls.Repeater.CreateControlHierarchy(Boolean useDataSource) +443
       System.Web.UI.WebControls.Repeater.OnDataBinding(EventArgs e) +51
       System.Web.UI.WebControls.Repeater.DataBind() +75
       Telerik.Search.WebControls.Admin.ControlPanel.LoadMainScreenTemplate() +382
       Telerik.Search.WebControls.Admin.ControlPanel.CreateChildControls() +54
       System.Web.UI.Control.EnsureChildControls() +87
       System.Web.UI.Control.PreRenderRecursiveInternal() +44
       System.Web.UI.Control.AddedControl(Control control, Int32 index) +8678021
       System.Web.UI.ControlCollection.Add(Control child) +80
       Telerik.Cms.Web.UI.ServiceList.CreateChildControls() +1009
       System.Web.UI.Control.EnsureChildControls() +87
       System.Web.UI.Control.PreRenderRecursiveInternal() +44
       System.Web.UI.Control.PreRenderRecursiveInternal() +171
       System.Web.UI.Control.PreRenderRecursiveInternal() +171
       System.Web.UI.Control.PreRenderRecursiveInternal() +171
       System.Web.UI.Control.PreRenderRecursiveInternal() +171
       System.Web.UI.Control.PreRenderRecursiveInternal() +171
       System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +842
    

    This seems to be originating from the "last search index" date displayed on the page.

    Is there anyway by which we could resolve this issue? Would it involve digging around in the database? Finally, is there a likely cause for this problem?

    Thanks for all your help guys,
    Nick
  2. Ivan Dimitrov
    Ivan Dimitrov avatar
    16072 posts
    Registered:
    09 Dec 2016
    10 Sep 2009
    Link to this post
    Hello Nick,

    Have you made changes to the following template - ~/Sitefinity/Admin/ControlTemplates/Search/ControlPanelMain.ascx and especially the line shown below:

    <li><asp:Literal ID="Literal3" runat="server" Text="<%$ Resources:LastIndexingDate %>"></asp:Literal>:&nbsp;<strong><sfWeb:DateTimeLiteral runat="server" ID="date" DateFormatString="dd MMM yyyy, hh:mm" /></strong></li> 

    Have you made any changes to the computer culture or something else that could be related like localization.

    Kind regards,
    Ivan Dimitrov
    the Telerik team

    Instantly find answers to your questions on the new Telerik Support Portal.
    Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
  3. Nick
    Nick avatar
    91 posts
    Registered:
    04 Aug 2008
    10 Sep 2009
    Link to this post
    This file has not been changed, i went on the live server and checked this, and it is identical to what you posted!

    It is highly unlikely that anyone has changed anything on this server, so i am wondering whether it could be a DB issue? As you said, could it be due to some localisation settings changing in the database?

    Thanks for your help with this :-)
  4. Ivan Dimitrov
    Ivan Dimitrov avatar
    16072 posts
    Registered:
    09 Dec 2016
    10 Sep 2009
    Link to this post
    Hello Nick,

    There is no information about the date in database. What the error says is that incorrect format string is used for DateFormatString property in the control above. Could you try to change this format with something different like "d" . You can gather more information about Custom Date and Time format string from MSDN.
    If the problem persists you should probably delete your indexes from the database.

    Sincerely yours,
    Ivan Dimitrov
    the Telerik team

    Instantly find answers to your questions on the new Telerik Support Portal.
    Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
  5. Nick
    Nick avatar
    91 posts
    Registered:
    04 Aug 2008
    11 Sep 2009
    Link to this post
    Thanks for the advice Ivan!

    Strangely though, the problem seems to have disappeared without any change made (i decided to check one last time before applying the changes to the string format you suggested)

    To prevent this problem recurring in future i think i will delete the search index (as we do not use it at all).

    Thanks again, your eagerness to help is much appreciated :-)
Register for webinar
5 posts, 0 answered