projects-and-solutions

Copying Visual Studio project file(s) to output directory during build

此生再无相见时 提交于 2019-11-26 20:06:47
问题 When I build a Visual Studio project, the executable is written to the output directory specified in the projects Property Page. I have a project that has some extra files (e.g., .ini file) that are used by the program. How can I configure the project to copy the file to the output directory so that when the program runs, it has a copy of the other file in its CWD? I checked the Property Page of the file and there was nothing useful other than an option to exclude it from the build (which is

Visual Studio open files question

巧了我就是萌 提交于 2019-11-26 19:57:46
问题 Is it possible to open a project in Visual Studio 2008 without opening all the files that were previously opened last time I had the project open. I have a habit of keeping many files open as I am working on them, so next time I open the project, it (very slowly) loads up a bunch of files into the editor that I may not even need open. I have searched through the settings and cannot find anything to stop this behavior. 回答1: Simply delete the .suo file. It contains the list of open files. 回答2:

Easy way to add multiple existing .csproj to a Visual Studio Solution?

我们两清 提交于 2019-11-26 19:11:52
问题 I've checked out a branch of C# code from source control. It contains maybe 50 projects in various folders. There's no existing .sln file to be found. I intended to create a blank solution to add existing solutions. The UI only lets me do this one project at a time. Is there something I'm missing? I'd like to specify a list of *.csproj files and somehow come up with a .sln file that contains all the projects. 回答1: Here is a PowerShell version of Bertrand's script which assumes a Src and Test

Visual Studio Solutions / Multiple project : How to effectively propagate project properties amongst several C++ projects

僤鯓⒐⒋嵵緔 提交于 2019-11-26 18:55:48
问题 I am working with a Visual Studio 2005 C++ solution that includes multiple projects (about 30). Based upon my experience, it often becomes annoying to maintain all the properties of the projects (i.e include path, lib path, linked libs, code generation options, ...), as you often have to click each and every project in order to modify them. The situation becomes even worse when you have multiple configurations (Debug, Release, Release 64 bits, ...). Real life examples: Assume you want to use

How do you organize your version control repository?

只谈情不闲聊 提交于 2019-11-26 18:02:45
First, I know about this: How would you organize a Subversion repository for in house software projects? Next, the actual question: My team is restructuring our repository and I'm looking for hints on how to organize it. (SVN in this case). Here's what we came up with. We have one repository, multiple projects and multiple svn:externals cross-references \commonTools /*tools used in all projects. Referenced in each project with svn:externals*/ \NUnit.v2.4.8 \NCover.v.1.5.8 \<other similar tools> \commonFiles /*settings strong name keys etc.*/ \ReSharper.settings \VisualStudio.settings \trash /

How to save DLLs in a different folder when compiling in Visual Studio?

心不动则不痛 提交于 2019-11-26 17:38:44
问题 Let's suppose I have a Window Forms / Console Application C# project with some external references and references to other class library projects in the same solution too. When I build the Window Form project, I want the referenced libraries be stored in a different location (eg: bin\Release\Libraries ), and not in the same folder as the .exe . Is it possible to do? 回答1: There are 2 parts of your question: How to configure solutions to build assemblies/EXE into folders of your choice - this

What is the significance of ProjectTypeGuids tag in the visual studio project file

懵懂的女人 提交于 2019-11-26 17:09:59
What is the significance of the ProjectTypeGuids tag in a visual studio project?? When I created a WPF application, i am seeing two GUIDs in here. {60dc8134-eba5-43b8-bcc9-bb4bc16c2548};{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}** Does these represent WPF and Windows type of applications? If I create my own project type (.myproj) that has .xaml and .cs files, what should I fill in this ProjectTypeGuids tags? Should I also need to fill the ProjectType tag? It would also be better if someone differentiate the ProjectType and ProjectTypeGuids*tags. Julien Hoarau {FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}

Error: Cannot access file bin/Debug/… because it is being used by another process

[亡魂溺海] 提交于 2019-11-26 15:46:49
When I debug my project, I get following error: "Unable to copy file "obj\Debug\My Dream.exe" to "bin\Debug\My Dream.exe". The process cannot access the file 'bin\Debug\My Dream.exe' because it is being used by another process." Using Process Explorer, I see that MyApplication.exe was out but System process still uses it although I stopped debug before. Whenever I change my code and start debug it is going to happen. If I copy project to USB and debug, it runs OK. Why? How can I fix this error? I use Window 7 Professional. With Xp I have never got this error. Cody Gray Ugh, this is an old

ASP.NET Web Site or ASP.NET Web Application?

旧巷老猫 提交于 2019-11-26 14:48:17
问题 When I start a new ASP.NET project in Visual Studio, I can create an ASP.NET Web Application or I can create an ASP.NET Web Site. What is the difference between ASP.NET Web Application and ASP.NET Web Site? Why would I choose one over other? Is the answer different based on which version of Visual Studio I am using? 回答1: Website: The Web Site project is compiled on the fly. You end up with a lot more DLL files, which can be a pain. It also gives problems when you have pages or controls in one

Structuring projects & dependencies of large winforms applications in C#

橙三吉。 提交于 2019-11-26 14:01:20
问题 UPDATE: This is one of my most-visited questions, and yet I still haven't really found a satisfactory solution for my project. One idea I read in an answer to another question is to create a tool which can build solutions 'on the fly' for projects that you pick from a list. I have yet to try that though. How do you structure a very large application? Multiple smallish projects/assemblies in one big solution? A few big projects? One solution per project? And how do you manage dependencies in