Copied to clipboard

Flag this post as spam?

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


  • coryn 24 posts 62 karma points
    Jan 28, 2012 @ 11:50
    coryn
    0

    DevExpress UserControls not rendering in Umbraco (4.7)

    Hey Guys,

    I've spent the last 2 days trying to integrate some custom UserControls I obtained from the DevExpress ASP.NET Suite (http://devexpress.com/Subscriptions/DXperience/asp-features.xml) into Umbraco 4.7. When I add a custom UserControl made in VS2010 by just creating it as a macro and placing it in the Template, it works just fine.

    I figured that DevX need some kind of license for them to play along, so I checked the Web.config file and found license tokens etc. So I thought: Add these to the Umbraco Web.config file and everything should be hunky dory!

    Sadly... They are still not showing, I'm not getting an error or anything, they simply just don't appear on the page or in the pagesource.

    Has anyone got any ideas?

     

    Cheers,

    Behati

  • Jeroen Breuer 4908 posts 12265 karma points MVP 5x admin c-trib
    Jan 28, 2012 @ 13:32
    Jeroen Breuer
    0

    Hello,

    Maybe you should start with a clean empty website (not umbraco). Create a simple usercontrol there with your devexpress stuff and see if that works. Once you got it working there you can try the same stuff in Umbraco (move over dll files, web.config changes, etc). Perhaps you're forgetting something and you might find it out this way.

    Jeroen

  • coryn 24 posts 62 karma points
    Jan 28, 2012 @ 13:36
    coryn
    0

    Hi Jeroen,

    thanks for the reply - I have successfully used DevExpress controls in previous projects, where I have either created a completely blank .NET web application in VS2010 or used the VS "starter kit" Webapp project - it worked fine in both scenarios.

    You're probably completely right that I'm just forgetting to copy over some crucial file to my Umbraco website.. but I can't for the life of me figure out which one(s)!

    I've tried copying over the entire bin folder from a VS webapp with DevX controls into Umbraco - no luck :(

     

    Behati

  • Jeroen Breuer 4908 posts 12265 karma points MVP 5x admin c-trib
    Jan 28, 2012 @ 14:07
    Jeroen Breuer
    0

    Have you enabled debugging? Maybe you can see something in your trace. Try to add ?umbDebugShowTrace=true to the end of your url where you should see your dev controls.

    Jeroen

  • coryn 24 posts 62 karma points
    Jan 28, 2012 @ 14:49
    coryn
    0

    Okay well I finally got it to show me an error (atleast) - Sadly I have little clue what it means.. Any thoughts?

     

    Error reading usercontrols/Filemanager/Filemanager.ascx
    
    The following list shows the Public Properties from the Control. By checking the Properties and click the "Save Properties" button at the bottom, umbraco will create the corresponding Macro Elements.
    
    System.Web.HttpParseException (0x80004005): 'Umbraco_Project1.usercontrols.WebUserControl1' is not allowed here because it does not extend class 'System.Web.UI.UserControl'. ---> System.Web.HttpParseException (0x80004005): 'Umbraco_Project1.usercontrols.WebUserControl1' is not allowed here because it does not extend class 'System.Web.UI.UserControl'. ---> System.Web.HttpException (0x80004005): 'Umbraco_Project1.usercontrols.WebUserControl1' is not allowed here because it does not extend class 'System.Web.UI.UserControl'. at System.Web.UI.TemplateParser.ProcessError(String message) at System.Web.UI.TemplateParser.ProcessInheritsAttribute(String baseTypeName, String codeFileBaseTypeName, String src, Assembly assembly) at System.Web.UI.TemplateParser.PostProcessMainDirectiveAttributes(IDictionary parseData) at System.Web.UI.TemplateParser.ProcessException(Exception ex) at System.Web.UI.TemplateParser.ParseStringInternal(String text, Encoding fileEncoding) at System.Web.UI.TemplateParser.ParseString(String text, VirtualPath virtualPath, Encoding fileEncoding) at System.Web.UI.TemplateParser.ParseString(String text, VirtualPath virtualPath, Encoding fileEncoding) at System.Web.UI.TemplateParser.ParseFile(String physicalPath, VirtualPath virtualPath) at System.Web.UI.TemplateParser.ParseInternal() at System.Web.UI.TemplateParser.Parse() at System.Web.Compilation.BaseTemplateBuildProvider.get_CodeCompilerType() at System.Web.Compilation.BuildProvider.GetCompilerTypeFromBuildProvider(BuildProvider buildProvider) at System.Web.Compilation.BuildProvidersCompiler.ProcessBuildProviders() at System.Web.Compilation.BuildProvidersCompiler.PerformBuild() at System.Web.Compilation.BuildManager.CompileWebFile(VirtualPath virtualPath) at System.Web.Compilation.BuildManager.GetVPathBuildResultInternal(VirtualPath virtualPath, Boolean noBuild, Boolean allowCrossApp, Boolean allowBuildInPrecompile, Boolean throwIfNotFound, Boolean ensureIsUpToDate) at System.Web.Compilation.BuildManager.GetVPathBuildResultWithNoAssert(HttpContext context, VirtualPath virtualPath, Boolean noBuild, Boolean allowCrossApp, Boolean allowBuildInPrecompile, Boolean throwIfNotFound, Boolean ensureIsUpToDate) at System.Web.Compilation.BuildManager.GetVPathBuildResult(HttpContext context, VirtualPath virtualPath, Boolean noBuild, Boolean allowCrossApp, Boolean allowBuildInPrecompile, Boolean ensureIsUpToDate) at System.Web.UI.TemplateControl.LoadControl(VirtualPath virtualPath) at umbraco.developer.assemblyBrowser.Page_Load(Object sender, EventArgs e)
    
    
  • Jeroen Breuer 4908 posts 12265 karma points MVP 5x admin c-trib
    Jan 28, 2012 @ 15:01
    Jeroen Breuer
    0

    Hmm strange exception. I assume that your usercontrol inherits from System.Web.UI.UserControl? 

    How do you place the usercontrol on your page? You can do it with a macro like in this video: http://umbraco.com/help-and-support/video-tutorials/introduction-to-umbraco/developer-introduction/using-net-user-controls/TVPlayer

    Or you can just place the usercontrol on your template/masterpage like you do in a normal webforms project.

    Jeroen

  • coryn 24 posts 62 karma points
    Jan 28, 2012 @ 15:03
    coryn
    0

    I create a macro from the UserControl file and then place the macro in my template in the usual way.

     

    Is there any reason to do it differently?

    And yes I'm pretty sure it inherits System.Web.UI.UserControl.

  • Jeroen Breuer 4908 posts 12265 karma points MVP 5x admin c-trib
    Jan 28, 2012 @ 15:06
    Jeroen Breuer
    0

    You don't have to do it differently. If you add the usercontrol without a macro you can't use macro parameters and macro caching, but maybe you should try it to see if that might work.

    Jeroen

  • coryn 24 posts 62 karma points
    Jan 28, 2012 @ 15:15
    coryn
    0

    Thank you very much for all your help, Jeroen! (Hartelijk bedankt)

    I figured out a workaround, the problem was indeed the licensing concerning the DevX products - My workaround was to open my Umbraco Usercontrols folder as a Standalone Website in Visual Studio, and then adding the UserControl in there which then generated the required licensing files (which explains why normal UserControls worked but the DevX security simply blocked my UCs from rendering).

    So far I've gotten one of them to work, trying a few others now just to make sure it works fully!

     

    Thanks for all your help.

     

    Behati

  • coryn 24 posts 62 karma points
    Jan 28, 2012 @ 17:20
    coryn
    0

    Oh my god... I now have a control that works, but just randomly doesn't show the last part (including functionality). It's not a CSS problem, it just doesn't render the last bit in Umbraco.

    Anyone experienced this?

     ** EDIT ** Fixed by removing the entire starterkit.. Damn starterkits! ;)

     

Please Sign in or register to post replies

Write your reply to:

Draft