Copied to clipboard

Flag this post as spam?

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


  • Brendan Rice 538 posts 1102 karma points
    Jun 22, 2010 @ 13:55
    Brendan Rice
    0

    How do you debug a user control from within umbraco?

    Hi,

    I am developing a series of user controls and have a solution set up with Umbraco and a Web Project that copies the relevant files to the Umbraco folders on Post Build event.

    I am interested in finding out the best way to debug the user controls as currently I am building and running umbraco to test them, this means I completetly loose the ability to debug through Visual Studio.

    Any help with this would be really appreciated.

    Thanks,

    B

  • Seth Niemuth 275 posts 397 karma points
    Jun 22, 2010 @ 14:50
    Seth Niemuth
    0

    In visual studio, add an existing website (which will be the umbraco site) to your solution and set the website as the Startup Project. Then, when you debug, you can also be debugging your usercontrols.

  • Morten Bock 1867 posts 2140 karma points MVP 2x admin c-trib
    Jun 22, 2010 @ 15:07
    Morten Bock
    3

    You can also use the Debug -> Attach to process, and select the w3wp.exe (the IIS process), and the just run your umbraco website, and your debugger will be hit when you usercontrol is loaded.

  • Brendan Rice 538 posts 1102 karma points
    Jun 22, 2010 @ 16:11
    Brendan Rice
    0

    Thanks for the reply Seth, this wouldn't work for me as I am hooking into Umbraco to create members.

    I have added in the required DLLs and config settings but I must be missing something.

    I checked SQL profiler and noticed that the following code was continually getting called when trying to debug my user controls

    Select userNoConsole, userDisabled, userType,startStructureID, 
    startMediaId, userName,userLogin,userEmail,userDefaultPermissions, 
    userLanguage, defaultToLiveEditing from umbracoUser where id = @id

    Any Ideas?

  • Sebastiaan Janssen 5060 posts 15522 karma points MVP admin hq
    Jun 23, 2010 @ 02:38
    Sebastiaan Janssen
    0

    Also have a look at my debugging set-up for Umbraco, might be of help.

Please Sign in or register to post replies

Write your reply to:

Draft