Questions tagged [.net-4.5]

Version 4.5 of the Microsoft .NET Framework. Use for questions specifically related to .NET Framework 4.5. For questions on .NET Framework generally, use the .net tag.

Reference

3775 questions
2
votes
3 answers

Casting Using ArrayList Under .NET4.5

All I have a utility method that is defined as public static Dictionary CountOccurences(IEnumerable items) { ... } I have some legacy code that unfortunately uses ArrayLists instead of List. Now, I need to cast the ArrayList to…
MoonKnight
  • 23,214
  • 40
  • 145
  • 277
2
votes
2 answers

Why is RavenDB hijacking my Nancy requests?

From a Winforms application using the same connection code, RavenDB works fine. I'm able to store and retrieve documents with abandon. When I try to do the same thing in a Nancy application the result is completely unexpected. Nancy is listening on…
nathanchere
  • 8,008
  • 15
  • 65
  • 86
2
votes
1 answer

ASP.NET Web API Controller Best Practice - Action Definitions

I'm running into a situation where my HttpGet action in my Web API controller has multiple ways to be called based on parameters specified in the query string. I need to be able to handle the following GET requests: ~/businesses/{businessId} …
aKulak
  • 43
  • 4
2
votes
1 answer

Best practices for working with sockets on a .NET 4.5 based game server?

I'm working on a relatively small shooter game project in C# that has to send over map data in chunks of voxels, together with player movement data, combat data and probably other stuff in the future. I already decided on using protobuf-net for…
Kelvin Bongers
  • 187
  • 2
  • 12
2
votes
2 answers

How to set e-mail expiration time in C# MailMessage

I have a problem with setting the expiration time of an e-mail. I use System.Net.Mail.MailMessage and I didn't find any property that will handle this. I've seen in Outlook that it is possible. I've done some search on StackOverflow, MSDN and Google…
Robert
  • 19,800
  • 5
  • 55
  • 85
2
votes
2 answers

Async with await do not work. Why?

When I try to run the code below, perform synchronous operations. Why? I get the following warning ... Warning 1 This async method lacks 'await' operators and will run synchronously. Consider using the 'await' operator to await non-blocking API…
Marcius Bezerra
  • 137
  • 1
  • 2
  • 11
2
votes
1 answer

An error occurred creating the configuration section handler error in .NET 4.5

I have a problem... nobody else can help so I wonder if anybody here can? I have a web service project (originally in .NET 2.0 but upgraded to .NET 4.5) which was working perfectly this morning. I also have a Winforms project which connects to the…
Jonny Wilson
  • 177
  • 4
  • 14
2
votes
1 answer

Object Initializer where property isn't assigned

I had a type-o in my windows-8 app store code. I got a strange result, so I went back to look and realized I missed a value, but it still compiled and ran without errors. Thinking this was strange, I went and tried it in a windows 8 console…
N_A
  • 19,799
  • 4
  • 52
  • 98
2
votes
1 answer

Windows 7 Tablet Button Double-Tap

I have developed an application to run on a Samsung Series 7 tablet. This application was developed using WPF, .NET 4.5, and C#. My problem is that sometimes a button does not receive input the first time it is tapped. For example, Window1 has a…
Robert
  • 400
  • 8
  • 23
2
votes
4 answers

Asp.net Bundle not render files .min

I've read and done the steps in this, this and this post! Still can not use the Asp.net Bundles! In Global.asax.cs BundleConfig.RegisterBundles(BundleTable.Bundles, Server); and ... public static void RegisterBundles(BundleCollection bundles,…
ridermansb
  • 10,779
  • 24
  • 115
  • 226
2
votes
0 answers

Implementing a claims-based security model to secure a WCF service

Currently, all of our web applications (and the WCF services they interact with) are run internally. Nothing is exposed to the web. We want to open up our web applications to the Internet and will need to secure access to the services. We have…
Thelonias
  • 2,918
  • 3
  • 29
  • 63
2
votes
4 answers

Factory pattern in C#

I was a bit able to understand Factory Pattern and came up with this implementation. class Program { static void Main(string[] args) { Console.WriteLine("Enter the fruit name to get the Fruit!"); string fruit =…
2
votes
1 answer

.Net Framework 4.5. Distributed transaction completed. Either enlist this session in a new transaction or the NULL transaction

I´m working on a distributed transaction issue that occurs using NET Framework 4.5. If I try to execute the app on a machine (and Dev Server also) using Framework 4.0 the components work fine. The problem started when I installed the fwk4.5…
2
votes
0 answers

What is the difference between EnumerablePartitionerOptions.NoBuffering and not using Partitioner at all?

In case I have a collection of objects that each object's process takes lots of time, what is the difference between EnumerablePartitionerOptions.NoBuffering and not using Partitioner at…
Stav Alfi
  • 13,139
  • 23
  • 99
  • 171
2
votes
1 answer

Consuming SharePoint 2010 WCF from .Net 4.5 + Store portable class library (PCL)

Can VS2012 build a proxy in a PCL project to consume a WCF service for SP2010? We add a reference (old school works everywhere else) but once we make calls, for instance GetListsCollectionAsync(), we get all sorts of errors. When we build the proxy,…
1 2 3
99
100