Copied to clipboard

Flag this post as spam?

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


  • bh 408 posts 1395 karma points
    Apr 24, 2020 @ 15:07
    bh
    0

    Duplicating Umbraco Website into a New VS Project

    I have an umbraco website I've called myTemplate.

    I want to copy the necessary bits into a new VS project called mySite.

    I published everything from myTemplate into mySite except: publishedprofiles folder, assemblyinfo.cs and the obj folder

    But when I try to run mySite in debug mode it's like all of the umbraco bits can't be found even though they are physically in mySite.

    What am I missing?

  • Alex Skrypnyk 6132 posts 23951 karma points MVP 7x admin c-trib
    Apr 24, 2020 @ 15:53
    Alex Skrypnyk
    0

    Hi Ben,

    Are you running mySite as an Application or WebSite in the VS?

    If you running as Application you have to include in project cs files to make it work.

    For the website mode, it should work just from bin or app_code folder.

    Thanks,

    Alex

  • bh 408 posts 1395 karma points
    Apr 24, 2020 @ 16:02
    bh
    0

    I'm trying to run it as application. I've got all my modelsbuilder *.generate.cs files

    What am I missing?

    I've got umbraco in the Bin, but it's like everything Umbraco is "missing a directive or assembly reference", or "does not exist in current context".

  • bh 408 posts 1395 karma points
    Apr 24, 2020 @ 17:35
    bh
    100

    Figured it out. The references didn't come over. This got me where I needed to be...

    Nuget Package Manager Console:

    Update-Package -Id UmbracoCMS –reinstall
    Update-Package -Id Umbraco.ModelsBuilder.Api –reinstall
    
  • Alex Skrypnyk 6132 posts 23951 karma points MVP 7x admin c-trib
    Apr 24, 2020 @ 18:05
    Alex Skrypnyk
    0

    Thanks for sharing!

Please Sign in or register to post replies

Write your reply to:

Draft