Umbraco Package – User Control File Tree

A few months ago, Tim Geyssens (aka Umbraco rockstar) released a package that gave you access to the *.config files in the /config/ folder. This has been a lifesaver in those few times where I have only had web-access to an Umbraco install and needed to tweak some config settings.

Recently I found myself in the same situation, but this time I needed to quickly update a few text changes to an ASCX user-control. Due to the nature of the .NET user-controls in Umbraco, there is no native way of accessing/editing those files via the admin back-end.

… well, not until now …

Following on from Tim’s lead with the Config Tree package, I have developed a “User Control File Tree” for the developer section.

This package displays all the user-control files (from the /usercontrols/ folder), allowing you to edit the front-end ASCX code/mark-up.  (There is no way to edit the code-behind using this package).  If the user-control contains any inline code (C#/VB.NET), then you will be able to edit it.  Keep in mind that there is no validation when editing the user-controls – so please be careful!

You can download the User Control File Tree package from here.

I created the package using Umbraco 4′s built-in Create Package Wizard. Please note that this package has been designed to work with v4 (and above), apologies to v3 users.

To install the package, go to the Developer section of your Umbraco back-end, expand the “Packages” folder, click on “Install local package”, select the “User_Control_Files_Tree_1.0.zip” (from wherever you saved it) and press the “Load Package” button.  Follow a few more on-screen steps and you’ll be done in no time!

If you have any problems with it, please do let me know – either by leaving a comment here or posting a thread on the Umbraco forum.

9 thoughts on “Umbraco Package – User Control File Tree

  1. Cool. How about enable editing of files in the appcode folder? Then you can edit all functionality in a Runway package.

    Hmmm … maybe just enabling all files would be easier :-)

    /Jesper

  2. Pingback: Source Code Released for User Control File Tree Umbraco Package « Lee Kelleher’s Weblog

  3. Very nice. Was about to do the exact same thing with the .config editor, when I decided to google first :)
    Thanks.

  4. Hey,

    in vs2010 i get the following error after i selected a .ascx file in the tree

    “Attempted to read or write protected memory”.

    VS2010, Umb 4.5.2, .net 3.5

    Has anyone sugesstions?

    BR
    Oliver

  5. I get the same error :(

    Attempted to read or write protected memory. This is often an indication that other memory is corrupt.
    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.AccessViolationException: Attempted to read or write protected memory. This is often an indication that other memory is corrupt.

    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:

    [AccessViolationException: Attempted to read or write protected memory. This is often an indication that other memory is corrupt.]
    System.EventHandler.Invoke(Object sender, EventArgs e) +0
    System.Web.UI.Control.OnLoad(EventArgs e) +99
    umbraco.BasePages.BasePage.OnLoad(EventArgs e) +49
    System.Web.UI.Control.LoadRecursive() +50
    System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +627

  6. Hi Lee
    Just recompiled this to work in 4.7.x and it’s working fine – if anyone need the dlls for this, just let me know.
    Couldnt find the App_Code editor, thats my next job to track the bugger down – see you at umbukfest
    Si