Questions tagged [visual-studio-2010]

Visual Studio 2010 is an integrated development environment (IDE) from Microsoft. Use this tag only for questions arising from the use of this particular version of Visual Studio, and not about any code just written in it.

Visual Studio 2010 is the version of Visual Studio preceding Visual Studio 2012 and succeeding Visual Studio 2008. It comes with partial C++11 support and the .NET Framework 4, as well as built-in tools for working with a variety of native, .NET and web development languages. It has integrated support for developing Microsoft Silverlight applications, including an interactive designer.

Visual Studio 2010 offers several tools to make parallel programming simpler: in addition to the Parallel Extensions for the .NET Framework and the Parallel Patterns Library for native code, Visual Studio 2010 includes tools for debugging parallel applications.

Visual Studio 2010 got its first service pack on March 3, 2011 with build number SP1Rel 10.0.40219.1.

More information:

46897 questions
1584
votes
5 answers

Why does changing 0.1f to 0 slow down performance by 10x?

Why does this bit of code, const float x[16] = { 1.1, 1.2, 1.3, 1.4, 1.5, 1.6, 1.7, 1.8, 1.9, 2.0, 2.1, 2.2, 2.3, 2.4, 2.5, 2.6}; const float z[16] = {1.123, 1.234, 1.345, 156.467, 1.578,…
GlassFish
  • 14,051
  • 3
  • 15
  • 22
901
votes
7 answers

push_back vs emplace_back

I'm a bit confused regarding the difference between push_back and emplace_back. void emplace_back(Type&& _Val); void push_back(const Type& _Val); void push_back(Type&& _Val); As there is a push_back overload taking a rvalue reference I don't quite…
ronag
  • 43,567
  • 23
  • 113
  • 204
694
votes
10 answers

Interop type cannot be embedded

I am creating a web application on the .NET 4.0 framework (beta2) in C#. When I try to use a assembly called "ActiveHomeScriptLib", I get the following error: Interop type 'ActiveHomeScriptLib.ActiveHomeClass' cannot be embedded. Use the…
Jan
  • 9,208
  • 6
  • 22
  • 33
657
votes
12 answers

Writing to output window of Visual Studio

I am trying to write a message to the output window for debugging purposes. I searched for a function like Java's system.out.println(""). I tried Debug.Write, Console.Write, and Trace.Write. It does not give an error, but it does not print anything…
previous_developer
  • 9,317
  • 6
  • 37
  • 57
536
votes
26 answers

Error 'LINK : fatal error LNK1123: failure during conversion to COFF: file invalid or corrupt' after installing Visual Studio 2012 Release Preview

I've installed Visual Studio 2012 Release Preview, and it appears to be fine, but now when I try to use Visual Studio 2010 to compile C++ projects, I get the following error message: LINK : fatal error LNK1123: failure during conversion to COFF:…
Orion Edwards
  • 113,829
  • 60
  • 223
  • 307
525
votes
4 answers

What is "stdafx.h" used for in Visual Studio?

A file named stdafx.h is automatically generated when I start a project in Visual Studio 2010. I need to make a cross-platform C++ library, so I don't/can't use this header file. What is stdafx.h used for? Is it OK that I just remove this header…
prosseek
  • 155,475
  • 189
  • 518
  • 818
498
votes
16 answers

The type or namespace name could not be found

I have a C# solution with several projects in Visual Studio 2010. One is a test project (I'll call it "PrjTest"), the other is a Windows Forms Application project (I'll call it "PrjForm"). There is also a third project referenced by PrjForm, which…
Anders
  • 14,647
  • 4
  • 30
  • 41
469
votes
16 answers

How do I run Visual Studio as an administrator by default?

I recently discovered that even while logged into my personal laptop as an administrator, Visual Studio does not run in administrator mode and you need to explicitly use Run As Administrator. Is there a way to make it run as an administrator by…
Kumar
  • 9,481
  • 10
  • 74
  • 126
455
votes
11 answers

Is there a format code shortcut for Visual Studio?

In Eclipse there is a shortcut, Ctrl+Shift+F, that re-indents code and fixes comments and blank lines. Is there an equivalent for Visual Studio 2010?
425
votes
44 answers

The name 'InitializeComponent' does not exist in the current context

If I create a new project in Visual Studio 2010 SP1 and select "WPF Application" and tries to build the generated application, I get the error The name 'InitializeComponent' does not exist in the current context. I got a similar error this morning…
user876402
  • 4,259
  • 2
  • 12
  • 4
402
votes
25 answers

Cannot import the keyfile 'blah.pfx' - error 'The keyfile may be password protected'

We just upgraded our Visual Studio 2008 projects to Visual Studio 2010. All of our assemblies were strong signed using a Verisign code signing certificate. Since the upgrade we continuously get the following error: Cannot import the following key…
JasonD
  • 7,202
  • 5
  • 28
  • 31
373
votes
13 answers

How to use Boost in Visual Studio 2010

What is a good step by step explanation on how to use the Boost library in an empty project in Visual Studio?
OlimilOops
  • 6,487
  • 6
  • 24
  • 36
355
votes
20 answers

This project references NuGet package(s) that are missing on this computer

I have an ASP.NET MVC5 application that worked yesterday and now I am getting this error when I try to build: This project references NuGet package(s) that are missing on this computer. I have the two options checked that allow nuget to…
Austin Harris
  • 4,462
  • 6
  • 23
  • 35
345
votes
2 answers

Running two projects at once in Visual Studio

I created a solution in Visual C# 2010 Express that contains two projects: one is the client, the other is the server. I would like to debug both at the same time, but I can only seem to run one of the projects during debugging. Is there a way to…
Tim Cooper
  • 144,163
  • 35
  • 302
  • 261
337
votes
17 answers

Type or namespace name does not exist

I have a WCF Data Service project built with Visual Studio 2010, which was working fine. All of a sudden, it didn't compile anymore. It was giving me messages like: Error 7 The type or namespace name 'Services' does not exist in the namespace…
Attilah
  • 16,382
  • 34
  • 132
  • 197
1
2 3
99 100