Christer
Christer

Reputation: 1681

Solution doesnt run/build/rebuild in Visual Studio

When trying to run Build / Rebuild in Visual Studio on a solution, nothing happens.

I can run the build from the command prompt using MSbuild.exe, and this gives me the output i would expect (Build succeeded) - But when trying to run it from visual studio, nothing happens. Theres no debug output or build output either.

The project is a MVC project, with some references to other projects.

I can create a new MVC project, and it runs just fine!

Any idea what might trigger this behavior?

Using Visual Studio 2015.

I Have tried the following:

That beeing said, the solution is inside a git repository, and the other person working on this project has entered at a later stage with Visual Studio 2013 - But i dont know if this has anything to do with the issue.

Upvotes: 6

Views: 12670

Answers (4)

Glauber
Glauber

Reputation: 41

Check whether any NuGet packages are missing, that was the problem with me. Go to

Tools -> NuGet Package Manager -> Package Manager Console

If any packages are missing, Visual Studio will show you a message and a "Restore" button to fix the problem. After that the application should build.

Upvotes: 0

DSA
DSA

Reputation: 780

Try this:

  1. Go to Tools -> Options -> Projects and Solutions -> Web Package Management
  2. Under that UNCHECK option "$(VSINSTALLDIR)\Web\External".
  3. After UNCHECKING the "$(VSINSTALLDIR)\Web\External" option, Restart Visual Studio and try to rebuild project.

Upvotes: 1

Christer
Christer

Reputation: 1681

So what seemed to happen was that there was some kind of dependency on a separate git repository (bootstrap), in our private repo that i hadnt been getting access too - so instead of giving me an error about it it just silently failed. Adding access to the repository to my account, suddenly made the project run again.

Upvotes: 3

amit dayama
amit dayama

Reputation: 3326

Go to your configuration Manager and make sure build checkbox is selected for your project.

other thing you can try is: Go to tools > Options>> A window will pop up> Under Project and Solutions > select Build and Run

Make sure Before building is set to Save all changes

Upvotes: 1

Related Questions