Build error: "Metadata file '.dll' could not be found" in WPF project
Hello everyone! I'm a beginner in C# and WPF (learning from an old textbook for Visual Studio 2008, C# 3.0). I have a solution with two projects: a main WPF project (MyApp) and a class library (MyLibrary). In MyApp, I added a reference to MyLibrary, but when I try to build the solution, I get the error:
"Metadata file 'C:\Projects\MyApp\MyLibrary\bin\Debug\MyLibrary.dll' could not be found"
Here is the code from MyLibrary (a simple class):
```csharp
using System;
namespace MyLibrary
{
public class Calculator
{
public int Add(int a, int b)
{
return a + b;
}
}
}
```
In MyApp, I'm trying to use this class:
```csharp
using System;
using System.Windows;
using MyLibrary;
namespace MyApp
{
public partial class MainWindow : Window
No answers yet.
Log in to leave an answer
Blogs