.NET Blog

Free. Cross-platform. Open source. A developer platform for building all your apps.

Featured posts

Announcing .NET 9
Nov 12, 2024
29
38

Announcing .NET 9

.NET Team
.NET Team

Announcing the release of .NET 9, the most productive, modern, secure, intelligent, and performant release of .NET yet. With updates across ASP.NET Core, C#, .N...

.NETASP.NET CoreC#

Latest posts

.NET Framework Documentation Improvements
Feb 19, 2013
0
0

.NET Framework Documentation Improvements

Brandon Bray
Brandon Bray

The CLR documentation team has been busy responding to feedback and making updates and changes to the .NET Framework documentation in the MSDN Library. We would like to tell you about the most recent set of document updates, which were published earlier in February. Performance content We have received extensive customer feedback regarding the importance of performance in .NET Framework apps, and we wanted to make it easier for you to find relevant content. As a result, we’ve reworked the existing performance and reliability topic to include more performance guidance as well as links to performance analysis t...

Getting a MIME type from a file extension in ASP.NET 4.5
Feb 14, 2013
0
0

Getting a MIME type from a file extension in ASP.NET 4.5

Jim Wang (WEB)
Jim Wang (WEB)

If you've ever implemented a file upload or download scenario in ASP.NET, you've likely come across the situation of having to provide a MIME type based off of a file extension. IIS does this automatically when it serves files, but it seems like in ASP.NET there isn't a good way to provide this functionality. Searches on the web might point you to building your own Dictionary of MIME types or just writing a switch statement, but this felt like a hack to me and so I turned to a resident expert, Levi Broderick.It turns out in ASP.NET 4.5 we shipped a little-known new type, System.Web.MimeMapping, which has an API c...

Protect your Queryable API with the validation feature in ASP.NET Web API OData
Feb 6, 2013
0
0

Protect your Queryable API with the validation feature in ASP.NET Web API OData

Hongmei Ge
Hongmei Ge

In the previous blog post, you can see how easy it is to enable OData query syntax for a particular action using Web API OData. Simply add a Queryable attribute to your action as follows, and you are done. It not only works for those actions using OData format, but also applies to any vanilla web api actions using other formats such as JSON.NET. It greatly reduces the need to write a lot of actions to perform operations like top, skip, orderby as well as filter. It is so powerful that it is almost hard to imagine building a real Web API application without it. Now everything works beautifull...

Getting started with ASP.NET Web API OData in 3 simple steps
Jan 29, 2013
0
0

Getting started with ASP.NET Web API OData in 3 simple steps

Youssef Moussaoui - MSFT
Youssef Moussaoui - MSFT

With the upcoming ASP.NET 2012.2 release, we’ll be adding support for OData to Web API. In this blog post, I’ll go over the three simple steps you’ll need to go through to get your first OData service up and running: Before we dive in, the code snippets in this post won’t work if you’re using the RC build. You can upgrade to using our latest nightly build by taking a look at this helpful blog post. 1) Creating your EDM model First, we’ll create an EDM model to represent the data model we want to expose to the world. The ODataConventionModelBuilder class makes this this easy by using a set of conv...

ASP.NET MVC, Data Access, and Deployment Content Maps Published
Jan 25, 2013
0
0

ASP.NET MVC, Data Access, and Deployment Content Maps Published

Tom Dykstra - MSFT
Tom Dykstra - MSFT

We are pleased to announce the publication on the ASP.NET site of three guides to ASP.NET documentation resources: The content maps provide links to good quality up-to-date tutorials, articles, blogs, videos, and forum and StackOverflow threads. The guides exist on MSDN, but we’re publishing updated versions on the ASP.NET site now in hopes that they’ll get more use and generate more feedback.  With your help, we hope to update them every 4-6 weeks with the latest and best links. The top of each page includes an invitation to email us with suggestions: If you know a great blog post,...

Introducing SvcPerf – An End-to-End trace Analysis tool for WCF
Jan 23, 2013
0
0

Introducing SvcPerf – An End-to-End trace Analysis tool for WCF

Sajay Antony
Sajay Antony

Standardizing on ETW In 4.5 we introduced ETW tracing for WCF. In the past couple of months we have been trying to establish some common tools that can be used to debug and analyze ETW traces from WCF. We have a large number of tools that allow ETW analysis and the one aspect we wanted to do was to allow activity correlation which WCF uses extensively. Folks who have already used ETW in its full capacity already know about ETW activities and how they are propagated. Those of you who don't, this FAQ: Common Questions for ETW and Windows Event Log should be a good start point. Others who just want to jump in, hop ...

XDT (web.config) transform engine released on NuGet
Jan 10, 2013
0
0

XDT (web.config) transform engine released on NuGet

Sayed Ibrahim Hashimi
Sayed Ibrahim Hashimi

We have just released the XDT transform engine on NuGet, with a license which allows you to redistribute the assembly with your own product. . If you are not familiar with XDT it is a XML transformation engine which drives our web.config transforms in Visual Studio. You can read more about XDT at here. You can now take a dependency on XDT and ship it with your own product.For specifics on the terms of use please read the license. Why are we doing this?One of the top 10 most voted features for NuGet is Support Visual Studio (XDT) web.config transforms. To summarize the request, NuGet package authors would like to ...

Real Scenario: folder deployment scenarios with MSDeploy
Jan 9, 2013
0
0

Real Scenario: folder deployment scenarios with MSDeploy

Sayed Ibrahim Hashimi
Sayed Ibrahim Hashimi

Hi everyone Sayed here. I recently had a customer, Johan, contact me to help with some challenges regarding deployment automation. He had some very specific requirements, but he was able to automate the entire process. He has been kind enough to agree to write up his experience to share with everyone. His story is below. If you have any comments please let us know. I will pass them to Johan. I’d like to thank Johan for his willingness to write this up and share it. FYI if you’d like me to help you in your projects I will certainly do my best, but if you are willing to share your story like Johan it will motivate...

Dual Mode Sockets – Never create an IPv4 Socket again
Jan 8, 2013
0
0

Dual Mode Sockets – Never create an IPv4 Socket again

Chris R
Chris R

The Problem:If you’ve worked with network programing in recent years you’ve probably had to grapple with the IPv4 vs. IPv6 issue at some point.  In short, IPv6 is a great new technology for the future of networking, but most applications will still have to support IPv4 for several years during the transition. Working at the socket layer developers most commonly address this by creating both an IPv4 and IPv6 socket and then juggling them back and forth as needed. Some existing System.Net APIs do this for you, such as: These APIs were a helpful mitigation but they only covered a subs...