Windows Phone 8

Windows Phone 8 Samples Update

WpDevCenter

The Windows Phone Developer team has updated / added new samples to help developers making great applications for Windows Phone. Each sample contains enough information for you to start learning a new feature or just get a idea for a new application. Open your Visual Studio and start downloading the samples. Here is the list of the last updated samples:

Source of the article Windows Phone Developer Blog.
All the Windows Phone samples can be found at http://code.msdn.microsoft.com/wpapps.

Windows Phone Map control and ZoomLevel limits

ZoomLevel
The Oscars are over, I was playing with my application Earthquakes for Windows Phone and I noticed a bug in the map control. The problem is very simple, but I’d like to share it here with you Windows Phone developers so you don’t make the same mistake.
Like a lot of application that use the Map control, I have two buttons in the ApplicationBar that allow me to zoom in and zoom out.

ZoomLevelActions

So, when you use the Map control for Windows Phone 7 or Windows Phone 8, you can use the property ZoomLevel to zoom in or zoom out. On the click of the button I was simply increasing or decreasing the value without doing any control. I know that’s bad… Apparently, there is a limit for the zoom level that can be apply to the Map. Which is 1 to 19 for Windows Phone 7 and 1 to 20 for Windows Phone 8.

For Windows Phone 7 you can use the following code to change the ZoomLevel property:

private void BtZoomMore(object sender, EventArgs e)
{
   map.ZoomLevel = Math.Min(map.ZoomLevel + 1, 19);
}

private void BtZoomLess(object sender, EventArgs e)
{
   map.ZoomLevel = Math.Max(map.ZoomLevel - 1, 1);
}

And for Windows Phone 8:

private void BtZoomMore(object sender, EventArgs e)
{
   Map.ZoomLevel = Math.Min(Map.ZoomLevel + 1, 20);
}

private void BtZoomLess(object sender, EventArgs e)
{
   Map.ZoomLevel = Math.Max(Map.ZoomLevel - 1, 1);
}

Introduction to Windows Azure Mobile Services

MobileServices

Today I would like to write about one of the feature on Windows Azure that was created by the team of Scott Guthrie. This new service, still tagged as a preview in the Azure management console, allows you to make easier your developments for Windows Phone, Windows 8 and even iPhone and Android devices with:

  • Structured storage. You can send and retrieve structured data between your client device and Azure using JSON messages or with the Windows Azure Mobile Services SDK. The backend of this storage is a SQL Server database but you don’t have to take care of it. Windows Store C#, Windows Phone 8, iOS.
  • User authentication. You will be able using a very simple line of code to get your mobile users to authenticate using for example their Microsoft Account or Facebook to access some restricted data or just to be identify by your system. Windows Store C#, Windows Phone 8, iOS.
  • Push notifications. Send a push notification to display a toast or change the tile on the client device has never been easier. With one line of JavaScript embedded on Azure, you can send push notification to all of your users. Windows Store C#, Windows Phone 8, iOS.

Microsoft did an amazing job by creating a lot of content to help developers creating applications using Windows Azure and I’ve linked, for each feature mentioned above, the corresponding tutorial for Windows 8 and Windows Phone 8 apps or even iOS.

Ok, now that we have the big picture of what is Windows Azure Mobile Services, let’s code a little bit. For one of my project I’m working on, I needed to connect Mobile Services, not from a mobile device but from a Worker Role also hosted on Azure. The main problem is that the Mobile Service SDK is not working for other projects than Windows 8, Windows Phone 8 (in the .NET world). Remember what I said about the Structured storage? You can exchange data using JSON messages. So I’ll use the REST APIs to communicate with my backend.

Continue reading

BugSense is back with the support of Windows 8, Windows Phone 8, HTML 5

BugSense

I already talked about BugSense, this company that provides to the developers of mobile apps the power to track crashes and problems in their applications (way better than the solution provided by the Microsoft marketplace). They are constantly evolving, adapting to the new market, the new technologies and today they announced the Windows 8 SDK for C# and JavaScript!

If you are familiar with NuGet, it has never been so easy to integrate a third-party library in your current project. Right click on you project, then Manage NuGet Packages…

image_20

Windows Phone 8 SDK is available

Windows Phone logo

Back from Microsoft BUILD in Redmond, WA, Microsoft released the newest version of its mobile operating system: Windows Phone 8. You can download the SDK right away: Windows Phone 8 SDK. In order to use (and abuse) of all new features of this OS, I recommend you to watch the videos of the BUILD sessions about Windows Phone 8 on Channel 9.

To run the emulator you’ll need those two requirements:

  • Windows 8 Pro edition or greater
  • A processor that supports Second Level Address Translation (SLAT) (which my computer doesn’t have because it seems too old, only two years old)

See what’s new in Windows Phone 8. I’ll publish some article soon about how to use the new features like the NFC.