I’m setting up .NET 4.0 support on our CI server. I’ve installed .NET 4.0, and the .NET tools from the Windows 7.1 SDK. On .NET 2.0 and 3.5, that...
You can see what I’m trying (but failing) to do with the following code: protected T GetObject() { return new T(); } Any help would be greatly appreciated. EDIT:...
I am a bit of confused about Parallel.ForEach. What is Parallel.ForEach and what does it exactly do? Please don’t reference any MSDN link. Here’s a simple example : string...
This question already has answers here: How do you add a timer to a C# console application (12 answers) Closed 2 years ago. What is the best way to...
While converting a project that used SlimDX, and therefore has unmanaged code, to .NET 4.0 I ran into the following error: Mixed mode assembly is built against version ‘v2.0.50727’...
Certain System.Threading.Tasks.Task constructors take a CancellationToken as a parameter: CancellationTokenSource source = new CancellationTokenSource(); Task t = new Task (/* method */, source.Token); What baffles me about this is...
AFAIK, all it knows is that at some point, its SetResult or SetException method is being called to complete the Task<T> exposed through its Task property. In other words,...
I am updating a PowerShell script that manages some .NET assemblies. The script was written for assemblies built against .NET 2 (the same version of the framework that PowerShell...
I’m trying to compile my excel addin using C# 4.0, and started to get this problem when building my project in Visual Studio. It’s important to tell you that...
%windir%\Microsoft.NET\assembly\ is the new GAC. Does it mean now we have to manage two GACs, one for .NET 2.0-3.5 applications and the other for .NET 4.0 applications? The question...