Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Yovav Gad 41 posts 62 karma points
    Jan 06, 2011 @ 02:04
    Yovav Gad
    0

    obout grid control is not working when running under Umbraco

    I’m getting an error when trying to bind an obout grid under Umbraco

     

    Does anyone have a fix for this or do you know what can I do to resolve it ?

     

    I’ve just downloaded your latest obout version from January 5th, 2011 but still get this error,

    (it works fine if I run it on an external page – not under Umbraco)

     

     

    Please let me know if you have any suggestion.

     

     

    Server Error in '/' Application.


    The Controls collection cannot be modified because the control contains code blocks (i.e. <% ... %>).

    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.Web.HttpException: The Controls collection cannot be modified because the control contains code blocks (i.e. <% ... %>).

    Stack Trace

    at System.Web.UI.ControlCollection.Add(Control child)
    at Obout.Grid.Grid.CreateReferencesForAppearanceResources()
    at Obout.Grid.Grid.CreateChildControls(IEnumerable dataSource, Boolean dataBinding)
    at System.Web.UI.WebControls.CompositeDataBoundControl.PerformDataBinding(IEnumerable data)
    at Obout.Grid.Grid.ExecuteRebinding(Boolean forced)
    at Obout.Grid.Grid.RaisePostDataChangedEvent()
    at System.Web.UI.Page.RaiseChangedEvents()
    at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)

     

  • Aaron Powell 1708 posts 3046 karma points c-trib
    Jan 06, 2011 @ 02:19
    Aaron Powell
    0

    Are you adding it via a macro? If so you can't have inline code in the ASCX file from what I recall.

  • Yovav Gad 41 posts 62 karma points
    Jan 06, 2011 @ 17:09
    Yovav Gad
    0

    I also tried loading the user control directly (with no macro) but I get the same results.

  • Yovav Gad 41 posts 62 karma points
    Jan 06, 2011 @ 17:45
    Yovav Gad
    0

    Solved thanks to Chris from obout.

    We had a head tag with runat="server" that caused it

    <head runat="server"> changed to just <head>

    I think there is a dynamic script injection somewhere, I'll try using <%# instead of <%=

Please Sign in or register to post replies

Write your reply to:

Draft