This project is read-only.

Missing using directive or assemble reference?

Jan 19, 2012 at 7:22 PM
Edited Jan 19, 2012 at 7:48 PM

I just installed VWD 2010 EE.  I created a new wep application project named BlogEngine and dropped the BE 2.5 files into this project's directory.  I replaced the default files created by VWD and merged the default folders with the BE 2.5 ones that were duplicates.  Then I included all of the files.  Got 300 errors on first build.  Adding a reference to the BlogEngine.Core.dll resolved most of this.  It got it down to 96 errors.

I now have a similar issue but cant seem to solve it in a similar way.  I am running VWD 2010 as Administrator.  Most of these 96 errors are still namespace or using statement issues but I can't get things into scope or correct these.  

For example, The tags.aspx.cs file in the Admin.Posts namespace has an error for the using statement " using App_Code;" statement at the top of the file.   I can't seem to get it to qualify fully by adding a reference.  Or at least not any that I've tried.  I tried to add a "using BlogEngine;" at the top of the file.  When I did this namespace came into scope but the App_Code folder wasn't an option.  The only two options for this namespace were the Account and Core Namespaces.  I can't seem to qualify or identify the namespaces correctly.

I don't understand what's wrong.   I can revert to last successful build and it will run.  I'm not sure if I messed something up when I merged the folders or what.


// this is from the Tags.aspx.cs code behind file.  you can also see the commented out BlogEngine using statemnt I added

namespace Admin.Posts
    using System;
    //using BlogEngine;  // added this to try to fix the error
    using App_Code;    // this is original


    public partial class Tags : System.Web.UI.Page
        protected void Page_Load(object sender, EventArgs e)
Jan 19, 2012 at 7:53 PM

Try this doc, if it doesn't help search for "convert to web application" - I've seen several step-by-steps for different versions.

Jan 19, 2012 at 8:16 PM


Thanks.  I'll give it a try.   I don't understand why in the article  you recommended, it says "As you can see, current source plays nicely with Web Application project model".  I used the web application model for my project.  So, it doesn't play nicely if this is the same issue.  I hope it does fix the issue but that would almost make it more confusing.

Jan 19, 2012 at 10:19 PM

Web site and web application are different models, you can't drop files from one to the other and expect it to work. Just as you couldn't drop web application files into MVC site - it does require adjustments. BE relatively easy to adopt to WAP, and that "play nicely" meant that you mostly do standard conversion and don't run into BE-specific issues as in earlier BE versions.

Jan 20, 2012 at 8:26 PM

thanks for the help.  There were no issues when I dropped the files into a Website project, which I think will be fine for my purpose.  It was up and running on the first build.  I can always convert it to WAP later if I choose.