Copied to clipboard

Flag this post as spam?

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


  • sebnunes 1 post 21 karma points
    Oct 01, 2012 @ 09:51
    sebnunes
    0

    UserControls cannot de loaded

    Hi all, 

    I'm currently migrating an existing site to Umbraco and I'm having troubles to have my aspx pages (transformed to user controls) loaded in Umbraco. 

    I followed the steps described here: http://en.wikibooks.org/wiki/Umbraco/Samples_and_Articles/Dot_Net_Controls/Using_Dot_NET_Controls_With_Umbraco

    After the user control is added as a macro I'm getting an Exception when I click on "Browse Properties":  The relative virtual path 'usercontrols/TestUserControl.ascx' is not allowed here. at System.Web.VirtualPath.FailIfRelativePath(). 

    I created a new blank project with one simple user control with only html in it and I still have the same problem. 

    Here is the detailed track trace: 

    System.ArgumentException: The relative virtual path 'usercontrols/TestUserControl.ascx' is not allowed here. at System.Web.VirtualPath.FailIfRelativePath() at System.Web.Hosting.HostingEnvironment.MapPathActual(VirtualPath virtualPath, Boolean permitNull) at System.Web.Hosting.HostingEnvironment.MapPathInternal(VirtualPath virtualPath) at System.Web.Hosting.HostingEnvironment.MapPath(VirtualPath virtualPath) at umbraco.IO.IOHelper.MapPath(String path, Boolean useHttpContext) at umbraco.IO.IOHelper.ValidateEditPath(String filePath, String validDir) at umbraco.developer.assemblyBrowser.Page_Load(Object sender, EventArgs e)

    Any idea why I'm having this problem?

    Kind regards. 

  • Mike Chambers 636 posts 1253 karma points c-trib
    Oct 01, 2012 @ 10:14
    Mike Chambers
    0

    common problem with 4.8.? just add a leading / infront of the path to the usercontrol in the macro settings. Then save... 

    '/usercontrols/TestUserControl.ascx'

    Then "browse properties" won't throw that error...

Please Sign in or register to post replies

Write your reply to:

Draft