visual-studio-2012

How do I permanently set a new Default project in the VS NuGet Package Manager console?

烈酒焚心 提交于 2020-01-01 08:18:17
问题 I am using VS2012 and every time I reopen VS, the Default project in the NuGet Package Manager console has been reset to what seems like a arbitrary project, and I have to use the dropdown list to reset to the appropriate project. How can I set (and persist this setting) for the default project for the package manager console? 回答1: As it stated in documentation here Package Manager Console's Default Project is whatever project set as StartUp Project on your solution level. You can control

What happened to “Exclude from Source Control” in VS2012

谁说我不能喝 提交于 2020-01-01 07:55:28
问题 I want to exclude some of the files in code folders from TFS 2012 source control. Before VS2012 this was done by the "Exclude from source control" command available in "Source Control Explorer"s right-click menu. But in VS2012 I can not find it. Does anybody know where it is ? (I am using a "Local" workspace by the way.) 回答1: When you click on "Detected Changes" in the Team Explorer pane, "Promote Candidate Changes" window opens. This window allows you to select among detected changes and

C# Couldn't process file xxx.resx due to its being in the Internet or Restricted zone or having the mark of the web on the file

笑着哭i 提交于 2020-01-01 07:36:48
问题 I have issue while i try to build project in VS2012. Can't build due to error: Couldn't process file xxx.resx due to its being in the Internet or Restricted zone or having the mark of the web on the file. Remove the mark of the web if you want to process these files. similar question is here Couldn't process file resx due to its being in the Internet or Restricted zone or having the mark of the web on the file but I try that option and have no luck, because I didn't downloaded file from

Can't load project after pulling: “Expected 'ENCODING' but found 'utf-8'.”

♀尐吖头ヾ 提交于 2020-01-01 07:34:10
问题 After pulling the project (WPF application) from git, I get this error: What could be causing it? It worked fine before pulling it (someone else commited on the project). 回答1: It appears there were some unclosed tags in my .csproject file. Strangely though, the error above was reported instead. 回答2: Look at your .csproj extension file search for: <<<<<< or ====== or >>>>>>>> and remove it. also check your web.config file for those symbols and remove them too if they exist there. 回答3: I had

How to embed an icon (.ico) in a static library (Visual Studio)

倖福魔咒の 提交于 2020-01-01 07:21:08
问题 Is there a way to embed resources (such as icons, dialogs) in a c++ (Win32 API) static library? My purpose is to embed an icon in the static library in a way that functions that use LoadIcon will work as if it was a normal .exe so the main application can only link to the static library and include a header file, with no requirement to add other files such as .rc files, or .ico files, etc. Clearly the main application who uses the static library doesn't have this resource so LoadIcon will

why does visual studio delete my classes when I update entity framework model

依然范特西╮ 提交于 2020-01-01 05:18:05
问题 I'm having a strange problem when I update my EF model (ver 5). It deletes all of the classes that belong to that model. My situation was like this. I changed the key column of two tables which have references to my primary table. Updating the model did not make these changes to the edmx, so I removed those three table (primary and two lookup tables), saved the edmx. Then updated the model and added those tables back in. Once I saved the model after updating it, VS deleted all of the class

Using C#, how do I create a new Visual Studio 2012 Solution programmatically?

那年仲夏 提交于 2020-01-01 05:17:30
问题 I followed this Stack Overflow post regarding how to create a project for VS2010, hoping that it would point me in the correct direction, but it doesn't cover creating a VS2012 project or solution. I also explored using SLNTools, but I don't see how to create a new solution from scratch. Ultimately, I would like to create 3-4 VS2012 projects programmatically and then add them to a solution which is also created programmatically. I attempted a solution based on this Stack Overflow post, but I

Has Microsoft removed Visual Studio 2012 Express links for good? [closed]

寵の児 提交于 2020-01-01 04:57:08
问题 Closed. This question is off-topic. It is not currently accepting answers. Want to improve this question? Update the question so it's on-topic for Stack Overflow. Closed 2 years ago . Recently I've been trying to download Visual Studio 2012 Express, but I failed to find it. One day the links were there, and the next day all of them were replaced by 2013 editions. Even Google and Microsoft's own search in their Downloads site find 2012 editions, but when I open links I see that they are 2013

When adding new C# projects in Visual Studio, additional configurations are not created automatically [duplicate]

假装没事ソ 提交于 2020-01-01 04:31:14
问题 This question already has answers here : Custom solution configuration not showing up in Visual Studio 2010 (4 answers) Closed 6 years ago . I have a Visual Studio C# solution which I have added a new solution configuration to. When I create new projects in the solution they have Debug and Release configurations only. Why do they not have the additional configurations? 回答1: Understanding Build Configurations says: By default, projects created with Visual Studio include Debug and Release

MSBuild error MSB4018 in VS2015: The “Link” task failed unexpectedly

拟墨画扇 提交于 2020-01-01 04:21:09
问题 After upgrading a solution with 25 projects from VS2012 Update 4 to VS2015 RTM (14.0.23107.0), I get the following error while building one of the projects: (...) MSB4018: 'The "Link" task failed unexpectedly. (...) System.NullReferenceException: Object reference not set to an instance of an object.' (...) Here the full output: 1>------ Build started: Project: Buttons, Configuration: Release Win32 ------ 1>C:\Program Files (x86)\MSBuild\Microsoft.Cpp\v4.0\V140\Microsoft.CppCommon.targets(643