Tuesday, February 21, 2012

Reset the back of your Tile through push

Reset the back of your Tile through push


Reset the back of your Tile through push

Posted: 21 Feb 2012 12:26 PM PST

Have you ever created the back of your tile with a Push notification? You just add some xml in the Notification Message that you send to the Notification Channel. <wp:BackBackgroundImage>http://someurlinthewild.com/BackTileBackground.png</wp...( read more )...(read more)

SilverlightShow for February 13 - 19, 2012

Posted: 21 Feb 2012 09:58 AM PST

SilverlightShow for February 13 - 19, 2012 Check out the Top Five most popular news at SilverlightShow for Feburary 13 - 19, 2012. Here are the top 5 news on SilverlightShow for last week: The Gradual Decline in Silverlight Adoption Windows 8's five biggest...( read more )...(read more)

Monday, February 20, 2012

ASP.NET Web API and HttpClient Available on NuGet

ASP.NET Web API and HttpClient Available on NuGet


ASP.NET Web API and HttpClient Available on NuGet

Posted: 20 Feb 2012 11:35 AM PST

If you don't need the full ASP.NET MVC 4 installer with project and item templates for Visual Studio 2010 then you can download the various ASP.NET Web API packages directly from NuGet (see list of packages below). If you are new to NuGet then it is a Visual Studio extension that makes it easy to add, remove, and update libraries and tools in Visual Studio projects that use the .NET Framework (check out the NuGet overview ). NuGet Packages Here are the relevant NuGet packages depending on what you want to build: Web API hosted in ASP.NET: AspNetWebApi Self-hosted Web API: AspNetWebApi.Selfhost HttpClient including XML and JSON formatters: System.Net.Http.Formatting JsonValue for navigating and manipulating JSON: System.Json Additional Information...(read more)

Windows 8 and the future of XAML: Part 3: Using WinRT

Posted: 20 Feb 2012 09:33 AM PST

In this third part of our exploration of Windows 8 and WinRT, we're going to start applying the concepts we learned about in the 2 first parts by using them in code. By now, you should have a good understanding of what Windows 8 Metro style applications...( read more )...(read more)

Visualising StackOverflow Tag Relationships with Silverlight

Posted: 20 Feb 2012 03:52 AM PST

Recently I have been wondering about the wealth of information that can be gleaned from the 2.5 million programming question on Stack Overflow. A few weeks back I found a tag trending tool, which can be used to measure the rise and fall in popularity...( read more )...(read more)

ASP.NET MVC 4 Beta

Posted: 19 Feb 2012 06:00 PM PST

A few days ago we released the ASP.NET MVC 4 Beta .  This is a significant release that brings with it a bunch of great new features and capabilities.  The ASP.NET MVC 4 Beta release works with VS 2010 and .NET 4.0, and is side-by-side compatible with prior releases of ASP.NET MVC (meaning you can safely install it and not worry about it impacting your existing apps built with earlier releases).  It supports a "go-live" license that allows you to build and deploy production apps with it.  Click here to download and install it today. The ASP.NET MVC 4 Beta will also be built-into the upcoming VS11 / .NET 4.5 beta that is coming out shortly.  This week's beta doesn't work with the previous VS11 developer preview that shipped...(read more)

Impressions, slides and code from TechDays Belgium and Netherlands

Posted: 19 Feb 2012 02:30 PM PST

This week I was "on tour" in Belgium and Netherlands and presented 3 times: "MVVM Applied, From Silverlight to Windows Phone to Windows 8" (in Belgium and Netherlands) The goal of this session was to make people feel confident that the skills they acquired...( read more )...(read more)

Sunday, February 19, 2012

Using MongoDB with ASP.NET Web API

Using MongoDB with ASP.NET Web API


Using MongoDB with ASP.NET Web API

Posted: 18 Feb 2012 10:53 PM PST

MongoDB is a popular NoSQL database that makes it a great backend for Web APIs which lend themselves towards a document store rather than a relational store . In this blog we show how you can use MongoDB with ASP.NET Web API to build an ApiController with support for HTTP GET, PUT, POST, and DELETE. Our sample controller is a simple contact manager Web API which builds on many of the same concepts as in the tutorial " Creating a Web API that Supports CRUD Operations " so I would recommend that you skim that for background. In particular, the URI patterns are very similar to that of the tutorial: Action HTTP Method Relative URI Get a list of all contacts GET /api/contacts Get a filtered list of all contacts GET /api/contacts?$top=2 Get a contacts...(read more)

How far will Microsoft go with HTML ?!

Posted: 19 Feb 2012 05:20 AM PST

Let's face it people, if you can deliver your product in HTML without compromising on UI/UX then … you should !!! HTML is the ultimate cross platform technology, and that's the sad truth. I still do believe that Silverlight has … Continue reading...( read more )...(read more)

Saturday, February 18, 2012

Windows Dev News for February 18, 2012 - #0042

Windows Dev News for February 18, 2012 - #0042


Windows Dev News for February 18, 2012 - #0042

Posted: 18 Feb 2012 01:10 PM PST

Windows Dev News for February 18, 2012 - #0042 [SC1218] In This Issue: John Papa ( -2- ), András Velvárt , Daniel Egan , Matthias Shapiro , Ayad Boudiab , David Tong , Bary Nusz , Christian Schormann and Pam Keesey , Arturo Toledo , Shawn Wildermuth ...( read more )...(read more)

How to create a Web Deploy package when publishing a ClickOnce project

Posted: 18 Feb 2012 10:57 AM PST

The other day I saw a question on StackOverflow (link in resources below) asking How you can create a Web Deploy (AKA MSDeploy) package when publishing a ClickOnce project. The easiest way to do this is to use the Web Deploy command line utility, msdeploy.exe. With the command line you can easily create an MSDeploy package from a folder with a command like the following: %msdeploy% -verb:sync -source:contentPath="C:\Temp\_NET\WebPackageWithClickOnce\WebPackageWithClickOnce\bin\Debug\app.publish" -dest:package="C:\Temp\_NET\WebPackageWithClickOnce\WebPackageWithClickOnce\bin\Debug\co-pkg.zip"   Here you can see that I'm using the sync verb, along with a contentPath provider ( which points to a folder ) as the source and...(read more)

C++ Precon at Tech Ed 2012 – Orlando and Amsterdam

Posted: 18 Feb 2012 12:02 AM PST

At both Tech Ed North America 2012 (June 11th-14th) and Tech Ed Europe 2012 (June 26th-29th) there will be a C++ all day preconference! The title is C++ in 2012: Modern, Readable, Safe, Fast. Our C++ MVP Kate Gregory will deliver it and here's the abstract:

C++ is gaining momentum as a development language, so whether you've never used C++ or stopped using it a decade ago, it may be time to brush up on your skills. With a new standard release providing new keywords and capabilities, C++ is a  featured language for many of the new Microsoft technologies and enables some amazing speed-ups of your application using libraries like PPL and C++ AMP. What's more, Visual Studio offers tools to native developers that have only been available for managed developers in earlier versions. This all-day session will show you what all the fuss is about and give you the skills you need to understand the advantages of C++ today and how to start applying those benefits to your application.

There are three main categories of attendees who would enjoy this session:

 

  • It's perfect for those who used C++ a long time ago and need a refresher, a way to catch up with all that has happened to C++ in the last ten years.
  • Developers who have never written a line of C++ code, but are solid in C# or Java will know the basic syntax (if, while, etc) and be able to follow this session and see why there is so much excitement around C++ these days.
  • C++ developers who are not using Visual Studio and not developing for Windows can come and see how their C++ skills will translate to these technologies and how quickly they can be productive on a new platform.

This preconference is technical and has lots of code in it. It's not an "introduction to C++" that starts from scratch. It's about providing the inspiration you need to start using particular features and starting writing modern C++. While you're at TechEd, you can also attend some C++ breakout sessions to go deeper into particular technologies and tools that caught your interest. If you watched the sessions from the GoingNative 2012 conference, and could follow them, you know how much C++ programming has changed this century. If not, and you're curious what the buzz is about, come and find out! It's a great way to start your TechEd experience, June 10th in Orlando or June 25th in Amsterdam. We'll see you there!

Using JSON.NET with ASP.NET Web API

Posted: 17 Feb 2012 04:10 PM PST

Json.Net is a popular framework for working with JSON. In particular, it has a bunch of features that are not supported by the DataContractJsonSerializer such as being much more flexible in what kind of types it can serialize and exactly how they should be serialized. The ASP.NET Web API Beta supports an open-ended set of formatters that can read and write data to and from any media type you want to support. For example, if you want to support the vCard format which has the media type text/vcard (previously it was text/directory) media type then you can write a formatter for vCard and register it for the media type (or types) in question. The complete sample is posted on Code Gallery . Note : If you are completely new to ASP.NET Web API then...(read more)

HttpClient: Downloading to a Local File

Posted: 17 Feb 2012 02:34 AM PST

Downloading content to a local file is a common thing to do. The current version of HttpClient doesn't yet provide out of the box support for saving content to a file but this sample shows how to extend HttpClient with new ways of reading content retrieved using HttpClient. This sample is also available on Code Gallery . ReadAs Extension Methods The HttpContent class contains content to be sent to a client (in the case of PUT, POST, etc.) as well as data being read from the server in a response. The basic System.Net.Http NuGet package provides support for reading the content as a stream, a string, or a byte array using one of HttpContent.ReadAsStringAsync HttpContent.ReadAsStreamAsync HttpContent.ReadAsByteArrayAsync The way to extend how an...(read more)

Push and Pull Streams using HttpClient

Posted: 16 Feb 2012 09:11 PM PST

One of the common discussions to have around network APIs is whether streams should be push or pull . That is, do you push content to the network, or does the infrastructure pull it from you and copy it to the network? In general there is no "right" way of determining this, it is a matter of taste and what fits more naturally in the object model in question. HttpContent is the common abstraction for any kind of content in HttpClient regardless of whether it be as part of an HttpRequestMessage or an HttpResponseMessage. Luckily it supports both patterns. The pull pattern is supported by StreamContent which is one of the default implementations of HttpContent. Here the input stream is read (pulled) by the infrastructure and copied to the network...(read more)

Extending HttpClient with OAuth to Access Twitter

Posted: 16 Feb 2012 01:41 PM PST

Many popular Web APIs such as the twitter API use some form of OAuth for authentication. HttpClient does not have baked in support for OAuth but using the HttpClient extensibility model you can add OAuth as part of the HttpMessageHandler pipeline. The HttpMessageHandler pipeline is the main extensibility point for the HTTP object model underlying both HttpClient and ASP.NET Web API (they use the exact same model). The pipeline allows up to insert message handlers that can inspect, modify, and process HTTP requests and responses as they pass by. The following diagram shows where HttpMessageHandlers sit in the message path on both client (HttpClient) and server side (ASP.NET Web API). The work like "Russian Dolls" in that each handler passes the...(read more)

HttpClient is Here!

Posted: 16 Feb 2012 01:59 AM PST

HttpClient is a modern HTTP client for .NET. It provides a flexible and extensible API for accessing all things exposed through HTTP. HttpClient has been available for a while as part of WCF Web API preview 6 but is now shipping as part of ASP.NET Web API and directly in .NET 4.5. You can also download it using NuGet – we just use the following three NuGet packages in this blog: System.Net.Http : The main NuGet package providing the basic HttpClient and related classes System.Net.Http.Formatting : Adds support for serialization, deserialization as well as for many additional features building on top of System.Net.Http System.Json : Adds support for JsonVaue which is a mechanism for reading and manipulating JSON documents In case you haven't...(read more)

Friday, February 17, 2012

Dear reader…

Dear reader…


Dear reader…

Posted: 17 Feb 2012 12:58 AM PST

My dear blog reader! For quite some time my blog being updated pretty slow and new posts are almost not showing up. I have to apologize for it! I never forgot about my readers! Lastly I've got few personal mails with the obvious questions arise – why...( read more )...(read more)

Windows Dev News for February 16, 2012 - #0041

Posted: 16 Feb 2012 06:41 PM PST

Windows Dev News for February 16, 2012 - #0041 [SC1217] I've got a bunch of posts queued up, but wanted to push the submittals first. In This Issue: Mark Monster ( -2- ), Dave Davis , Senthil Kumar B , Oscar Agreda , Colin Eberhardt , and Tony Champion...( read more )...(read more)

SilverlightShowTop 5 News for February 06 - 12, 2012

Posted: 16 Feb 2012 04:16 PM PST

SilverlightShowTop 5 News for February 06 - 12, 2012 Check out the Top Five most popular news at SilverlightShow for February 06 - 12, 2012. Here are the top 5 news on SilverlightShow for last week: Tile Flip Animation using XAML, Silverlight, and Expression...( read more )...(read more)

Thursday, February 16, 2012

Working with Prism 4 Part 4: Region Navigation

Working with Prism 4 Part 4: Region Navigation


Working with Prism 4 Part 4: Region Navigation

Posted: 16 Feb 2012 08:02 AM PST

This is part 4 in the series Working with Prism 4. Introduction At Microsoft ASP.NET Connections March 26- 29 2012 I'll be presenting a session on Prism development that includes the capabilities covered in this article – the URI-based navigation...( read more )...(read more)

Help Us Make Improvements

Posted: 15 Feb 2012 04:56 PM PST

The Microsoft Visual Studio Design Research Team is looking for developers to give us direct feedback on our development tools, languages and libraries! Opportunities include usability studies of upcoming features, focus groups where we explore new ideas, as well as 1:1 interviews.

Is this just about Visual Studio users?

You do NOT need to be a Visual Studio user! We are looking for all kinds of developers using a variety of tools and technologies.

What do participants get out of it?

Because we do many studies across all of our development tools, we always try to match participants' skill sets to the area we are studying. If you are selected to participate in one of our research studies, benefits include a combination of the following:

  • A chance to see and use upcoming tools, features, and language/library enhancements,
  • Interact directly with members of our development teams to discuss your requirements for efficient and effective tools,
  • Influence future design decisions, and
  • If you reside in the U.S. you receive a choice of a Microsoft product from our gratuity list!

We have a brief enrollment form that will ask you a few questions about your job and the development tools and technologies you actively use. We will contact you as soon as we have a research study that matches your specific background and/or interests.

This enrollment should only take 3-5 minutes to complete.

If you have any questions about participating, please feel free to contact vsdr@microsoft.com. To learn more about how we help protect your privacy visit our corporate privacy page. We are sorry, but government employees are not eligible to receive gratuities. However, we would still like you to participant in our studies.

[Go to the Enrollment Page]

Screenshots of my #mvvm demo at #techdaysbe

Posted: 15 Feb 2012 02:52 PM PST

Today I gave a talk in TechDays in Belgium about MVVM in Silverlight 5, Windows Phone 7 and Windows 8. This was the first time I gave that particular talk, and in addition keep in mind this is a developer preview, meaning that it is not finished, and...( read more )...(read more)

Tuesday, February 14, 2012

Unified Ad for Windows Phone - Part 4 - GenericAdProviderForXaml

Unified Ad for Windows Phone - Part 4 - GenericAdProviderForXaml


Unified Ad for Windows Phone - Part 4 - GenericAdProviderForXaml

Posted: 14 Feb 2012 12:31 PM PST

Alright, we have signed up to a lot of Ad Providers in Part 1 , setup the Unified Ad control in Part 2 and even implemented the Remote Ad Provider configuration in Part 3 . What's next? The Generic Ad Provider for Xaml Think of the Generic Ad Provider...( read more )...(read more)

UX Anti Patterns for Security on the Web and in the Enterprise

Posted: 14 Feb 2012 11:21 AM PST

I log into my local bank's website quite often. I transfer money between accounts and all the usual things. Today, when I logged in, I saw that they've decided to dump the security questions they had us answer earlier this year and replace them with a completely new and obscure set. If you don't set the security questions, you can't get to your bank account . Don't get between me and my money. Seriously. There's no better way to get on my bad side. In addition, they decided to make the questions really different from the usual set. I'm sure they feel like they're doing the right thing in the name of security, but here, they have failed. That got me thinking about security usability and other anti-patterns I've...(read more)

31 Weeks of Windows Phone Metro Design | 14 Using the Windows Phone App Bar

Posted: 13 Feb 2012 11:49 PM PST

...( read more )...(read more)

Windows Dev News for February 13, 2012 - #0040

Posted: 13 Feb 2012 10:15 PM PST

Windows Dev News for February 13, 2012 - #0040 [SC1216] In This Issue: Michael Palermo , Jesse Liberty , Jeremy Likness , Kirupa Chinnathambi , Beth Massi , Bill Lodin , Victor Gaudioso , Dhananjay Kumar , Sumit Dutta , and WindowsPhoneGeek . Above The...( read more )...(read more)