Its been more than a day on hitting my head on this error.
I tried with 4-5 solutions:-
- Create a Separate Class Library
- Creating a Class in the UI layer
- Adding a reference of debug/release dll
- Putting the dll into the bin folder of the UI layer
I deleted the actual class & put a simple calc class but still same error.
Error 5 The type or namespace name 'DocumentImport' could not be found (are you missing a using directive or an assembly reference?)
DocumentImport Class
namespace DocumentImport
{
public class Calc
{
}
}
UI Layer Controller-
using DocumentImport;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.Mvc;
namespace MyWebsite.Controllers
{
public class TestUtilController : Controller
{
public void GenerateHtml()
{
Calc obj = new Calc();
}
}
}
BuildOrder is as below:-
- MyWebsite.DAL
- DocumentImport
- MyWebsite UI
Any help/suggestion highly appreciated.