This question already has answers here:
How to reference a C# Class Library project in Visual Studio 2010?
(2 answers)
Closed 8 years ago.
I am trying to write a page that displays a flow Diagram to the user. I downloaded the Tree Chart Generator from: http://www.codeproject.com/Articles/20508/Tree-Chart-Generator and added the Tree Generator project to my solution. However, when I try to reference TreeGenerator from my code behind, it is not recognized. I am sorry if this is a simplistic question, I am pretty new to .NET development.
Go to your web site project in the Solution Explorer, right click, click Add Reference, and select the project you want to reference. You may need to change to a "Solution" tab depending on your version of Visual Studio. I'm assuming Visual Studio because you didn't provide that detail in your question.
Related
This question already has answers here:
Visual Studio 2019 hangs on "Execute Suggested Action" when adding a reference
(3 answers)
Closed 2 years ago.
While trying to add a reference to class in a unit testing class, it takes infinitly long time to execute. I am adding the reference through "Suggested action" shortcut.
I've attached an image below. This keeps going on. I have reinstalled VS, but the problem still there.
I've noticed that problem too, but in Visual Studio 2019 Professional some time ago. It has been fixed after an update.
Do you have any update to apply?
Anyway you should report the problem to Visual Studio community through the menu:
This is a boring problem but you can avoid it adding the reference manually using the Reference manager
This question already has answers here:
Unity Scripts edited in Visual studio don't provide autocomplete
(35 answers)
Closed 5 years ago.
I've just gotten started with programming in Unity. I installed Visual Studio Code 2017 recently on Zorin 12. It's a nice interface, but there's no auto-completion! I realize that Ctrl+Space pops up some suggestions, but there are two problems that I'd like resolved with this:
The suggestions don't pop up automatically
The suggestions are based on redundancies in code I've already typed, not suggestions based on unexplored capabilities of Unity. If I'm working with a Transform object, for example, I want it to pop up all of the possible variables I could use, not just the one I used earlier.
Two errors I get can be seen at https://i.imgur.com/AwHl4ef.png
Thank you for your consideration.
For Windows or macOS:
Download/Install the Visual Studio IDE (with Unity Tools)
When installing, make sure you include installation of
Game development with Unity
Then using Unity (you can double click one of your C# files), open a new C# project and the Visual Studio IDE should open with your new project structure.
From there, you should be able to see what you are looking for.
For example:
For Linux (suggestion):
Try Monodevelop - Additional Information, it provides code completion/hints.
This question already has an answer here:
Dotpeek recompile decompiled files
(1 answer)
Closed 6 years ago.
I have a c# project that includes a dll which I need to make changes to. So I decompiled it using dotpeek, exported the code and made my changes. Now I need to recompile it to add it back to my project.
The issue is that I am not sure if I am going about this problem the right way. And if I was how would I recompile the code into a dll again?
Sorry about this question but I am new to c# and visual studio but thank you for your help!
You will need to create a new C# project in visual studio, put the decompiled code in the new project and then you can convert the modified decompiled code back to dll which can be referenced in your project.
This question already has answers here:
How to use a class from one C# project with another C# project
(11 answers)
Closed 7 years ago.
Environment :
In C#, I have a solution with many project. They were added with *.csproj files.
Problem :
In a project, you can use classes of other files through namespace. However, is there a way to use namespace and classes of another project in the same solution?
In visual studio you should have a "References" area in the Solution Explorer. Right click that and click "Add Reference..."
From here, it's just a matter of locating where you other code is on your machine.
Edit: Here is some additional information on DLLs, in case it helps you.
This question already has answers here:
How do you share code between projects/solutions in Visual Studio?
(17 answers)
Closed 8 years ago.
I want to have a file with some enum's and use them in several projects in the same solution.
How could I use the same enums throught projects in the same solution instead of having to copy them into every .cs file?
Im from xcode and obj-c and not very used to Visual Studio c# :(
If you have multiple projects that need to share source code you would create a new project as a class library type. Add the code to that project and then add it as a reference to the other projects that need it. Visual Studio will then handle building and sharing of the code for you.
To use the code in those projects you will have to define the using of the shared project in the C# files that need it.
If you need more detailed instructions. Just let me know.