visual-studio-2010

Building .NET Application for Different Versions of Crystal Report in Visual Studio 2010

How Can i Build a .NET Application targeting different versions or probably the lower versions of the Crystal Report in Visual Studio . The Client Machine contains the Crystal Report 9 runtime as well as designer installed . Now is it run a .NET Application that uses Crystal Report Components in Visual Studio 2008 / 2010 that targets C...

Cross compile for .NET 4 and Silverlight 4 in VS2010 without duplicating files

We have a large number of projects within a solution mostly simple class libraries (which are later loaded through MEF) targetting .NET 4.0. We would like to compile a large number of these for both .NET 4.0 and the Silverlight runtime without duplicating files. Is there a way to create a new Silverlight class library and link the sour...

Merge Issues With Visual Studio 2010 Database Project Schema Compare & TFS

I am experiencing an issue working with a database project in Visual Studio 2010 Ultimate with TFS. The following describes the work flow that I use: I work locally modifying a SQL schema via SQL Server Management Studio. Next I open up the Visual Studio database project & perform a "Schema Compare" operation. I choose my local databas...

Class modifier for automatically generated classes

When I add a new class to a project, the class modifier/access specifier for the newly created class in Visual Studio is ommitted, thereby making it internal. Is there a way I can specify in Visual Studio settings that whenever I ask for a new class to be created, please make the class public? I looked in the Tools->Options menu but co...

How to ignore generated code from code coverage data

I am using Visual Studio 2010 and would like to exclude the generated service reference code from my code coverage statistics. I found an article pre 2010 that mentions using DebuggerNonUserCode and DebuggerHidden attributes. I have tried this an it works as advertised. DebuggerNonUserCode is set at the class level, but with 50+ classe...

Compatibility issue between VS2010, Pex, and SlimDX

I have downloaded June bits of Pex and June bits of SlimDX SDK. Installed them on my RTM VS2010 Premium. Pex explorations do not work. Reverting to Feb 2010 bits of SlimDX seem to cure the problem. I've asked the same question on Microsoft Forums and SlimDX forums, and neither party wants to own this. How can I even begin to troubles...

visual studio 2010 with c# like namespaces in vb

Is it possible to have visual studio 2010 automatically add namespaces to classes within folders just like c#? ...

VS2008 : Can't debug, error "AspNetHostingPermission"

Man, I'm having a rough day. I have a ASP.NET 2.0 application with AJAX extensions and I want to debug an unruly function. When I press Debug, it goes to compile the site, but it errors out : Error 945 Request for the permission of type 'System.Web.AspNetHostingPermission, System, Version=2.0.0.0, Culture=neutral, PublicKeyToken...

Splitting XAML Empty-Element Tags in Visual Studio

Quick question, and I hope I'm using the right terminology :) I'm using Visual Studio 10. Is there a keyboard shorcut for splitting an empty element tag? For example, I want to turn: <element /> into: <element></element> quickly. This is just a minor nuisance, but editing XAML, for a beginner like me, is very time consuming. I sp...

Get current TFS connection in a Visual Studio addin

I'm working on a Visual Studio 2010 add-in, and I'm trying to figure out how to determine the currently connected TFS server. I'm guessing I need to use DTE, but I'm having a brain cramp figuring out where to get the info. Any help is, of course, appreciated. EDIT: Actually, I may have found the answer, which I culled from a couple p...

Marshal.StructureToPtr crashes Visual Studio

I'm working on a custom debug engine and when I marshal my structure to a IntPtr Visual Studio crashes (the one being debugged not the debugger). My struct is little more than: public struct DocumentContext : IDebugDocumentContext2, IDebugCodeContext2 { private string _fileName; //.....Implementation of interfaces } My mar...

What are your top Visual Studio 2010 extensions?

Possible Duplicates: Best VS2010 Extensions Visual Studio 2010 - recommended extensions I've just discovered JSEnhancements for Visual Studio 2010 and it's left me wondering what other "indispensable" extensions and add-ins there are that I might benefit from. What are your key productivity extensions for Visual Studio 201...

Powershell and enums defined in C++/CLI assembly

I have an assembly written in C++/CLI that contains a heap of enum defined like the following, one after the other in a single header file. namespace Fix { public enum class Side { SideBuy = '1', SideSell = '2' }; } I can reference these types in other C# projects, and in IronPython, I can reflect the assembly and see them a...

visual studio 2010 - control source keeps disappearing

Hi, From time to time i cannot see the ascx control source (not code behind). The only way i can really reproduce this is: If you have two controls and click from ascx source to ascx source (to and from each control) rapidly then you will eventually get one of the controls showing nothing in the source. The way to fix this (annoying ...

64 bit version of VS2010 runs in 32 bit version

We have installed VS 2010 64 bit version on a 64 bit operating system but in the the Task Manager the image name for vs2010 display as *32. On searching in google it seems that the display indicates the VS 2010 is running on 32 bit version and we have the same issue we have in SQL2005. 64 bit version of .Net Framework is installed. Pleas...

Why are some references missed when running my application?

I have the following project structure using a Domain Model, StructureMap and Fluent NHibernate: The problem I'm having is that Fluent NHibernate requires all of the following to be the bin directory of the website for it to work at runtime: Antlr3.Runtime.dll * Castle.Core.dll Castle.DynamicProxy2.dll FluentNHibernate.dl...

very long build - ASP.MVC 2 in VS2010

I'm developing Asp.MVc 2 application. In solution i've about 10 projects and i have no idea why bulid takes so much time - ~5 minutes. I've tried to unload some projects, but it saves mayby 15 seconds. I'd like to try and learn TDD, but writing and running tests will waste 80% time. I'm using VS2010 and default MSBuild - is there any ...

Visual Studio 2010 "Preparing Solution" dialog

What the crap is this "Preparing Solution" dialog that VS 2010 shows when I open solutions? Does this show up for everyone or is something screwed up on my install? Anyone know what its actually doing? ...

Resource (RESX) files messed up

I had a resource file named Localize.resx, which contains English strings. I copied and pasted it inside the same folder(App_GlobalResources), VS created a copy, I renamed the copy to Localize.sl.resx and the original to Localize.en.resx. Now everything in codebehind files (Localize.en.designer.cs) is gone. Deleting the designer file and...

Third-party dll crashes program with no exception thrown

I am using Visual Studio 2010, and coding in C#. I have a third-party dll that I am using in my project. When I attempt to use a specific method, at seemingly random occasions, the program simply crashes, with no exception thrown. The session simply ends. Is there any way I can trace what is going on? ...