Its been more than a day on hitting my head on this error.

I tried with 4-5 solutions:-

  1. Create a Separate Class Library
  2. Creating a Class in the UI layer
  3. Adding a reference of debug/release dll
  4. 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?)

DLL available in the bin folder

Controller

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:-

  1. MyWebsite.DAL
  2. DocumentImport
  3. MyWebsite UI

Any help/suggestion highly appreciated.

0

There are 0 answers