Reputation: 1
I am developing a project using Visual Studio 2008 in C#, I have added the class library within the project and set up the relevant references and used the relevant using statements. It seems to be a problem with just this one folder. can anyone help?
this is the error message:
Error 28 The type or namespace name 'Domain' does not exist in the namespace 'Forestry.SchoolLibrary' (are you missing an assembly reference?) C:\Projects\SchoolofForestry\trunk\Source\School\Account\Presenter\EditAccountPresenter.cs 26 40 School
these are my using statements:
using System;
using System.Collections.Generic;
using System.Configuration;
using System.Linq;
using System.Data.Linq;
using System.Text;
using System.Xml;
using Forestry.SchoolLibrary.Core.Domain;
using Forestry.SchoolLibrary.Properties;
Upvotes: 0
Views: 391
Reputation: 14851
The error you are recieving doesn't seem to match your using statements. In the error, .NET is searching for the following namespace:
Forestry.SchoolLibrary.Domain
And in your using statement, you're referencing:
Forestry.SchoolLibrary.Core.Domain
I would check if you are explicitly referencing Forestry.SchoolLibrary in the line of code causing the error.
Upvotes: 1
Reputation: 1038930
That's because you have a type named Domain
and a namespace that ends with Domain
. This is bad as it generates some problems (for example the one you are encountering). So I would recommend you removing the Domain
part of the namespace or you could use the global::
identifier for a type:
var domain = new global::Forestry.SchoolLibrary.Core.Domain.Domain();
Of course as you can see this might get ugly.
Upvotes: 1