Build class library doesnt update reference in Visual Studio - c#

Visual Studio 2019 CE with all updates as of today.
I create a Blank Solution.
Add Empty web project to the blank solution.
Add a class library.
Reference the library in my web project.
I build the Solution and can tell the library is working as intended.
I make a small change to the class library and build the Class Library only. The change i made doesnt reflect the output im expecting. If i rebuild the entire solution then the change i made does take affect.
Normally i can just build the single library and that does the trick. I cant work out why the entire solution needs to be built in order for the changes to come across to the web project? I even deleted the CL and added a new one but the same occurs - am i missing a setting somewhere?

Related

Reference DLL project from a different solution in VS Studio 2019?

I have seen similar questions, but the solutions seem to be deprecated or not compatible with VS Studio 2019.
Basically, I am building a client and a server application. I am building each one in a separate solution.
In the client solution, I added a Class Library project, which includes some classes I'll need to use in the server solution.
So, I right clicked on References in my solution explorer, and tried to find the solution. I browsed to the supposed location of the DLL in the first solution, but the problem is that there doesn't seem to be any .DLL file despite the project being a "Class Library (dll)". The only file is ClassName.csproj and I can't add that one. I also can't manually add the .cs files since it says its not a dll.

How to create a Project Template without requiring PacMan (or refresh)?

If you create a new Windows UWP project in VIsual Studio 2015 using the out-of-the-box Blank template you will find that intellisense works without having to build or refresh the project.
Now, create a custom project template based on the Blank template. You will find that your new project template creates a project fine. However, that new project does not have intellisense until PacMan (the Nuget package manager) fetches Microsoft.NETCore.UniversalWindowsPlatform from the package cache.
After you invoke PacMan and fetch Microsoft.NETCore.UniversalWindowsPlatform, your new project will still not have intellisense. That is, until you refresh your project in Solution Explorer. At that point, you are in business.
My question. What is the setting in the VsTemplate.xml that enables a custom project template to create a project and immediately work? That is to say, what can tell Visual Studio to go ahead and run PacMan and refresh the project?
There is one requirement to this scenario. It is important that this custom template not have a custom project wizard. That is not a viable solution to this problem. I believe this can be solved with configuration, not code.
Please note, this question involves NuGet v3, not 2 or 1.
Does anyone know?

Automatically update references visual studio

I have a solution with a class library.
And then I have another solution with a web application which uses the dll above.
Everytime i make some changes on the class library I have to go to web application, remove the class library reference and add it again.
Is it possible to get this done automatically?

One or more project was not loaded properly

After copying the project to another laptop/ PC, when I want to open the solution, VS2010 shows the error "One or more project was not loaded properly". I have tried running visual studio in admin mode but that did not solve the problem.
This is usually a result of an inconsistency in your solution or projects. Open the solution file in an external editor (such as notepad) and check that the path it has to the projects is available and did not change. There shouldn't be any absolute paths in the solution file.
Maybe because the project from where you copied was configured with IIS configurations and you are trying to run the project in visual studio's default environment.
you have to right click on your project and set as a start up project after that you have run your project,
I seem to have found unloaded project, after noticing there's one missing by manually counting and comparing it to the number of projects the solution explorer reported. It was deep inside another folder in the solution explorer that I never used and assumed that had nothing worthwhile.
It's a familiar issue. Looks like the project you are trying to open was created in higher version than what you have. If the project is in MVC, make sure you have installed MVC OR Make sure you have appropriate version of .NET installed in your system.
I work with NopCommerce and a couple of times I downloaded new version and got same error message. It goes away once I install the dependencies.
Because you tagged it ASP.NET make sure you have all the ASP.NET components installed. Those are not part of .net framework but might be necessary in your project.

Can't compile/use ObjectListView in VS 2010

I want to use ObjectListView in a project coded in VS 2010.
Therefore I did the following things:
Downloaded the project
Opened both ObjectListView.sln to convert it to a VS2010 project
Added one of them to my project-folder in VS 2010
Added the project-assembly to my project
Added the namespace xmlns:o="clr-namespace:BrightIdeasSoftware;assembly=ObjectListView"
It compiles but it doesn't find any of its classes in my project. That means after entering the namespace: "
Does anyone know what I can do about that?
The ObjectListView project in the solution is missing "Filters.cs". It's located in the directory, just not added to the project.
Add it to the project, and everything will build (using VS2010, and ObjectListView.sln).
EDIT:
It looks like you're creating a WPF project. ObjectListView is intended to be used in WinForms applications.

Categories