I have two projects in a solution. One is a Web Part and the other a C# Class. I have added the reference to the C# class into the Web Part project and am able to see it and reference it via the code by adding a
using ReportingServices;
in the ascx.cs file. This runs and compiles with no issues.
I recently found need to reference the class file directly from the ascx file. I added the import statement
<%@ Import Namespace='ReportingServices' %>
I was able to add the text to the label using:
<Text='<%#ReportingServices.Common.formatMultiField(Eval("MylanCompanyName")) %>'
Intellisense recognizes the namespace and shows me the public functions. I cleaned the solution and rebuilt it with no errors or issues. However once it is running and I navigate to the page containing the web part I am receiving the CS0246 Type or Namespace ReportingServices Cannot be found.
I know the reference is there because the Using ReportingServices is working fine. So what am I missing that I cannot add an Import Statement?