Questions for visual-studio-2012


Making Linq operations to a database in Data Connections

I am using Visual Studo 2012 and SQLExpress.

Colors of fonts in package manager console with posh-git?

I'm trying to get the package manager console to look exactly like a standalone powershell console with posh-git. The only thing i've been unable to replicate is the red font used for files. Here i...

How to view SQL Server CE system tables in Visual Studio 2012

I can open a SQL Server CE 4.0 .sdf file in Visual Studio 2012 and it appears in the Server Explorer. All good.

How to convert char* to TCHAR? [duplicate]

char* stheParameterFileName = argv[1]; //I'm passing the file name as a parameter.

Windows Forms C# Tool location is not same

I'm developing an windows forms application using .NET C# and so far all code related are just fine. But, I got some UI trouble. I have this gauge that I'm using in the UI for displaying a connection

The type or namespace name could not be found (New to XAML)

So I'm trying to work a very simple dice app on a XAML document using Visual Studio 2012, but I can't figure out what to do with the error. I've tried adding using bitmapimage; but it still won't w...

Auto Uninstall WinRT App after Debugging Stopped

I want to automatically uninstall a WinRT app after it has finished debugging. Is this possible?
634 using a custom file to save different types of data

I'm brushing up on my VB.NET skills for a future project I will be working on. This application will be very data intensive, requiring 20+ data tables, user supplied images, and possibly even short

Visual studio 12 and regular expressions error

I am getting a strange error in VS2012.

ReSharper color identifiers screw up with Visual Studio 2012 dark theme

We're experiencing an annoying problem issues with ReSharper's color identifiers feature when Visual Studio 2012 is set to the built-in dark theme.

Error “nvcc cannot find a supported cl version” when compiling CUDA 5 with VS2012

I followed the instructions here to compile cuda 5 with visual studio 2012 but I'm still receiving this:

Error in loading Azure Storage 2.0 — could not load Microsoft.Data.OData 5.0.2

My hosted service uses Azure Storage 2.0 (exactly from Nuget). Under Visual Studio 2010 I had no problem. I switched to Visual Studio 2012 and now in some web site of my main web role I get...

Can I target .NET 4 and .NET 4.5 in the same Visual Studio solution (when using Entity Framework)?

I have a Visual Studio 2012 solution that consists of both a web application and some client-side code. The way the application is structured, there is a shared class library used for data access. ...

Best practice for using the 'volatile' keyword in VS2012

Since upgrading our development and build environments from VS2008 to VS2012, I am confused about the implications of using the volatile keyword in our legacy codebase (it's quite extensive as ther...

Unit testing a static class with a private static field that is a common dependency

I have a public static class I'm trying to unit test using Visual Studio 2012's built in testing framework. When I try to run unit tests on it I get this error:

Adding Tags as an Editable field In TFS work item template

In TFS 2102 Update 2 they have added tags for the work items by default these can be edited (added removed and view) via the web interface.

WebAuthBroker can't connect to service, but hand-posting in IE is succesful

I have a Windows 8 app that builds a string and posts to https: using WebAuthBroker. Relevant code is below.

Changing the Default EventHandler Naming in VS2012

There is an excellent extension for VS2010 that allows the user to change the default naming of event handlers:

Class Files not visible in Visual Studio 2011

I ran Visual Studio 2012 today and tried to create a new solution with projects contained within.

Visual Studio 2012 c++ intellisense comments for std possible?

Is it possible to get comments on c++11 std methods and classes in VS2012 ? Currently i'm only seeing parameters and return types - and they're a mouthful to interpret for someone learning cpp.

error C4335 when compile C++ project VS2012

I have a C project that i am able to compile and run successfully, however when i add another include like #include <vector> even without actually using the vector type i am getting the follo...

Azure Table Storage entity accessed via OData. PartitionKey and RowKey as Primary Keys

I'm accessing a "Person" entity using Azure Table Storage via OData (WCF Data Service). I was having lots of issues for getting this to work. I was having this error:

ASP.NET MVC 3 won't recognise .cshtml view files

I have ported an mvc 3 app from vs 2010 to vs2012.

Should I install visual studio 12

I'm doing a project with a couple of other guys who have vs10, will it hurt if just I upgrade to vs12. Will it hurt when we all check in on svn? Will everything still be compatible as far as wpf, m...

JavaScript Windows 8 app setInterval() issue

Basically I have this code in MS Visual studio 2012 for a windows 8 JavaScript+jQuery app.

Where are the database project and item templates in VS2012?

I asked this question about VS2010, because the location changed from where it was in VS2008, and I couldn't find it.

some solution files still have the VS10 icon

I have installed Visual Studio 2012 (aka 11) and uninstalled 2010. However I noticed that solution (.sln) files show an icon that has a little "10" on it while others have "11", with no seeming pa...

“Cannot update project reference” error introduced by Visual Studio 2012

I had a command line build which was working fine with Visual Studio 2010.

setup software with visual studio 2012 and install shield 2010

I have developed an application with Visual Studio 2012. I have also created a setup.exe with Install Shield 2010 Premium for my application. My development environment is Windows 8 64-bit, the

Visual Studio 2010 T4 Code Generation for Templated Types

I am using the default T4 templates to generate code based on my UML Model. I have a number of classes that expose Template Parameters. These generate code as expected. For example the MessageRespo...

Enabling Code First Entity Framework VS Web Express 2012

I am trying to enable Code First in my Visual Studio Web Express 2012. From what I have read so far I have to use the Package Manager Console and the command Enable-Migrations. When I do this I ge...

updating url rewriting rule with vs2012 web deployment web.config transformations

I can't figure out how to get my web.config deployment transformation to work for a rewrite rule. I've tried the following and it ignores it.

Visual Studio 2012 UI customization

Are there any add-ins available that let you customize the UI look and feel for Visual Studio 2012 IDE?

Resharper 7 on VS2012 ignores assembly redirect in app.config

We use moq and AutoMoq with mstest, and since upgrading to VS2012 and ReSharper 7, we the tests run fine with mstest, but fail when using the R# unit test runner with:

Visual Studio shows error CS0029 for types in non-global alias

I am writing a wrapper around two different versions of a communication library that work with different versions of my company's database. These communication libraries have classes with identical

Are Visual Studio 2012 product keys backwards compatible

Does anyone have any experience with using product keys for VS2012 within VS2010?

Productivity Power Tools for Visual Studio 2012

Is there a new version of the Productivity Power Tools for Visual Studio 2012 available? I miss the enhanced scrollbars, the solution navigator and the tabs on the left side (and not on the top) an...

TFS 2012 + Visual studio 2012: some settings options return “The user name or password is incorrect”

I've upgraded our TFS 2010 to TFS 2012 without any issues. I can connect to the source control, checkin, everything I need to Work.

error C2143: syntax error : missing ',' before '<'

The code below don't compile in vs 2012. In line 4 I got an error C2143: syntax error : missing ',' before '&lt;'. Can somebody help me to fix it. I would be very appreciate.

How do I target .NET 4.0.3 on XP using Visual Studio 2012? Application fails to run with “not a valid Win32 application”

I have a large application targeting .NET 4.0.3 that needs to run on XP. It builds fine using Visual Studio 2010 SP1 and runs properly on XP.

Virtualizing .NET framework

I have a .NET 4.0 based Winform application which I virtualized using Spoon Virtual Application Studio 2012.

Entity Framework Installation Fails & Crashes Visual Studio

I'm trying to install Entity Framework 5.0 into a Visual Studio 2012 Pro project. Part way through the install it fails and crashes Visual Studio. I suspect that it is trying to figure out which ...

My first project: Editing an .img file, guidance wanted

Note: The only programming experience i have can be found here(

How to make word wrap respect indentation in Visual Studio?

Visual Studio has a word wrap feature, but frustratingly it ignores line indents, making the text hard to read. Other text editors (Notepad++, Sublime Text) simulate the indentation of wrapped lines,

Export Visual Studio 2012 to 2010 sln format

My teacher is complaining that he can't read the VS2012 format on his VS2010 environment. I looked around in settings and so on but couldn't find anything. How can I give the project in an VS2010

Insert a new GUID to Visual Studio 2012

Is it possible to create a code snippet or something similar to automate the process of generating and inserting GUIDs in to the text editor in Visual Studio 2012?

Programming Languages in Visual Studio 2012 Installer

I've read in the Visual Studio blog that at least, in the setup for VS 2012 RC there was no way to select which programming languages to install.

Visual Studio 2012 - Coded UI Test Wont Run

I'm trying to create a Coded UI Test in Visual Studio 2012. When I add a new test VS will automatically start the recorder. I then do some basic clicks around in the WinForms application I want to...