LP Pinsonneault blog's

Windows 8, Windows Phone, ...

NAVIGATION - SEARCH

Create a Windows Phone app and win some prizes

Hi Canadian Windows Phone developers!
This year Microsoft Canada, created a nice contest (based on some post i saw on the web, other country are pretty jealous of us). So if you ever wanted to create apps for the Windows Phone, it now time to do so. So by publishing some nice apps, you may be rewarded with some cool prizes ( and yes they are very cool!). You can read all the information on the following website :  http://www.developermovement.com/.  Do like me and start find some ideas and create nice applications for one of the best phone!

Last week i find something nice. If you have an XBOX there is an advertisement for the Developer Movement. When you go, it give you some info about the contest and you can grab the wallpaper for your dashboard and a player picture. See some pictures :

P1000086

P1000087

WP_000078

 

 

 

 

I hope to install some of your nice apps!

Regards,
LP

Microsoft SharePoint 2010 Enterprise Applications on Windows Phone 7 Book

2589ENRecently i have the opportunity to work as a Technical Reviewer for a book written by Todd Spatafore. This book is about the creation of Windows Phone 7 application which integrate with SharePoint. Windows Phone 7 offer a native integration with SharePoint, but sometime you need to create enterprise application the will require to connect with SharePoint.

So if you are interested by the book, you can see more information on the PacktPub website:
https://www.packtpub.com/microsoft-sharepoint-2010-enterprise-applications-on-windows-phone-7/book

LP

Windows Phone 7–Network Connectivity

Recently I've been working on a project and we discovered something that have some impact on the performance of a Windows Phone application. This is probably a mistake that we did when implementing the code, but it may be the kind of mistake that many developer will do.

Quickly, each time we were calling the web service we were validating the network connectivity by validating the property “ NetworkInterface.NetworkInterfaceType ”. Behind that property, there is a process that validate the connectivity. This process is calling a page “http://www.msftncsi.com/ncsi.txt” to see if there is any connectivity and which type of connectivity. But the problem is that is done synchronously. So in our case we were calling multiple times this process, which result to execute the process of validating the Url mention before synchronously multiple times.  So each web service call must wait for the network validation before executing the call. And because it’s on the web the response can be fast and can also be very long before we get the response.

In our case we did implement a wrapper that make sure that the call is not done to often. This help us improve the performance of the application start-up. Also this help to improve activation process after the application Tombstone.

So make sure to validate our Windows Phone 7 application by using a tool like fiddler. This will help you improve the performance and stability of your application.

Regards,
LP

Windows Phone Controls

Almost 4 month have passed since the release on the market of the Windows Phone devices. With now over 8,000 apps, a lot of code have been written. So many controls manufacturer have release controls for Windows Phone 7. Some are free and some not. But in the end the is  now a good set of controls available on the market to help the developer to build nice and appealing application.

Silverlight Toolkit for Windows Phone (Free)

Recently, the Silverlight Toolkit for Windows Phone was update. This release provided some new controls and some improvement on the existing controls.

New feature:

  • TiltEffect
  • PerformanceProgressBar

Download: http://silverlight.codeplex.com/releases/view/60291

More information: http://www.jeff.wilcox.name/2011/02/feb2011-sl4wptk/

 

Telerik RadControls for Windows Phone (Paid)

Telerik is also providing some nice controls. Telerik provide nice transition and animation controls. We used some of those controls some of our recent project. They are currently in beta but they are working like RTM product. I had the chance to be in contact with the dev team to help us solving some issue in the beta and i can tell you that the team is really dedicated to provide the best controls.

  • Application Frame
  • Transition Controls
  • many more

Download: http://www.telerik.com/products/windows-phone.aspx
Sample App: zune://navigate/?phoneAppID=fd55f526-d6f7-df11-9264-00237de2db9e

telerik_radcontrols_0telerik_radcontrols_4

 

Component Art (Paid)

Last week ComponentArt released a version of their Data Vizualisation for Windows phone. This set of controls looks very nice (i didn’t time to test the control, but i will review the controls in a couple of days). If you plan to create a dashboard with some Charts, Gauges, Maps, Gridviews, etc i suggest you to give a look at this set of controls.

Sample App: zune://navigate/?phoneAppID=e13ba532-242b-e011-854c-00237de2db9e

Download: http://www.componentart.com/products/dv/wp7.aspx

componentart_demo_1componentart_demo_4componentart_demo_3

 

Coding4Fun Tookit (Free)

This open source project provide some nice feature that are not available in any other project. This project is a good complement and a good base for any Windows Phone project.

Controls:

  • About Prompt
  • Input Prompt
  • Progress Overlay
  • Round Button
  • Round Toggle Button
  • Memory Counter
  • TimeSpan Picker

Data Helper:

  • PhoneHelper for getting data out of the WMAppManifest file

Converter:

  • Boolean to Visibility
  • String To Visibility
  • Themed Image Converter
  • Inversed Theme Image Converter
  • Visibility to Boolean

Download: http://coding4fun.codeplex.com/

aboutPrompt_2_thumbbuttons_2_thumboverlay_2_thumb

 

WP7Contrib (Free)

This set of controls provide feature that help to work with MVVM Light. The feature are mostly behind the hood, like Cachine, Messaging, Service and some ui controls.

Download : http://wp7contrib.codeplex.com/

 

Developing application for Windows Phone 7 can now be done using some controls (without having to create them manually). Those controls provides rich visual and are easy to implement. So creating a portable dashboard for a sale department or a social network application is now an easy task with all those controls. So give it a try, like we did in our projects.

Regards,
LP

Windows Phone 7 now support Visual Basic developer

Last week finalized the implementation for the support of Visual Basic for the Windows Phone Developer Tools. So now any developer with Visual Basic background can now build Windows Phone application (and Game based on Silverlight).

So to be able to start building Windows Phone application with Visual Basic you need to have Visual Studio 2010 Pro or higher (at this time Visual Studio 2010 Express is not supported). You also require the Windows Phone Developer Tools and the addon for the support of Visual Basic (download here)

For more information, you can read the official post on the Windows Phone Developer Blog here.

Have a good time developing Windows Phone 7 application!

Regards,
LP

Useful links use in my Windows Phone 7 presentation at .NET Montreal

WP-vert-webYesterday i did a presentation on Windows Phone 7. I covered the end to end process of development of a Windows Phone 7 application. I’m happy to see the interest that the crowd showed about the subject. In my presentation I've talk about many feature, tools and component that are very useful.


So here is a the link list:

http://create.mdsn.com

Free Ebook

Training

Marketplace

ODATA

Tombstoning

Component

Tools

UI

Other good resources

On Twitter

  • #wp7dev
  • @gcaughey
  • @indyfromoz

 

This is a small list, but this will give you a good start.

Thanks to everyone who attend at my session last night, i had a great time presenting.

Enjoy developing for Windows Phone 7

LP

Windows Phone 7 – Suspend mode

Recently i was publishing an updated version of an application on the Marketplace for Windows Phone 7, and my update failed the testing process.

Why?

Comments: The user isuse  presented with an error message when the location services are disabled on the device. The error
message that is displayed is not a user friendly message.
Steps to reproduce:
1. Turn on location service on device.
2. Launch the application and select a location
on the venues page.
3. Swipe to the map page and select view map.
4. When map is loaded press the Start button on the device. 5. Go to the settings of the device and turn off location service.
6. Press the Back button from the Start screen of the device to reactivate the application.
7. Notice a non-user friendly error notification appears.

Real reason
In reality the problem is not related with the location services. Because i don’t use the location service (i only use the Bing Map for display only).  In fact, the real problem it’s that i forgot to handle the Deactivated event and the Activated event.

Why do we have to handle the Activated and Deactivated event?
Windows Phone 7 doesn’t support multiple application running at the same time (except for some application approve by Microsoft). But when your application is running, for different reason (incoming phone call, the user click the start button, …) the application can be suspended. To eliminate some issues you should handle those event and make sure you persist important information.

gg266441_788be805-086f-49cf-9911-fc638a953c92_png(en-us)

One of the best place to handle these events is in the App.xaml. To do so you need to declare the events in the xaml code.

<Application.ApplicationLifetimeObjects>
        <!--Required object that handles lifetime events for the application-->
        <shell:PhoneApplicationService
            Launching="PhoneApplicationService_Launching"    
            Closing="PhoneApplicationService_Closing"
            Activated="PhoneApplicationService_Activated"    
            Deactivated="PhoneApplicationService_Deactivated" />
    </Application.ApplicationLifetimeObjects>

In the Activated event, you can store some data in the the Microsoft.Phone.Shell.PhoneApplicationService.Current.State dictionary. And in the Deactivated event, we can retrieve that information.

Conclusion
Make sure to test any scenario that a user may face. Currently, the testing process that Microsoft implemented is pretty exhaustive (which is good because it help ensure that the application in the Marketplace won’t crash).

Reference
http://msdn.microsoft.com/en-us/wp7trainingcourse_applicationlifetimewp7lab_topic2.aspx
http://bolingconsulting.com/blog/?p=46

Regards,

LP

Windows Phone 7–Quick Jump Grid

Kevin Marshal of Clarity Consulting post a nice blog about the Quick Jump Grid. The Quick Jump Grid is a model propose in the design template by Microsoft but not available as built-in control at this time. So if you want to implement that kind of feature i suggest that you read the blog and test the demo.

http://blogs.claritycon.com/blogs/kevin_marshall/archive/2010/10/06/wp7-quick-jump-grid-sample-code.aspx

imageimageimageimage

 

Regards,

LP

Windows Phone 7 – Upgrading to the RTM version of the Developer tools for Windows Phone 7

Last week Microsoft released the RTM version of the Developer Tools for Windows Phone 7. This weekend i took some times to migrate the application that I’m creating for the TechDays .  The migration took me about less than 30 minutes.

I only had to fix one issue, which is related to the RTM version. The WMManifest.xml have changed since the Beta version. To fixe the issue i had to create a new Windows Phone 7 project and copy the WMManifest.xml file in my application. And the application was building again.

In the beta version, the Panorama and Pivot controls was not available as built-in control. There was a project on codeplex which provided the functionality. So moving to the RTM, was pretty simple. I only had to declare a namespace :
xmlns:controls="clr-namespace:Microsoft.Phone.Controls;assembly=Microsoft.Phone.Controls".
After what i have to change the control type. That was simple as that.

The Panorama and Pivot control are working perfectly and smooth. And much better than the other version.

Also they provide natively a Map control, which is a Windows Phone version of the Bing Map for Silverlight. I was waiting for that specific control for a long time. I only had to do a drag and drop and assign the CredentialProvider properties and the control was working.

Also the team who was working on the Silverlight Toolkit have created a version of the toolkit for Windows Phone. So i was able to use the WrapPanel from the Toolkit instead of importing some code file from the original Silverlight Toolkit.

For the emulator, it have been improved again. The start time have been improved.

In conclusion, i think as a developer we have all the tools we need to be able to build great Windows Phone 7 application.

What you need to download to start building Windows Phone 7 applications

Resources about Windows Phone 7

Regards,
LP

Install experience on a real Windows Phone 7 device

Last Friday Christian Beauclair of Microsoft did an install clinic in Montreal. So i scheduled an appointment to install the application I'm currently building for the TechDays. I was really impressed by the quality of the OS. It run really smooth and faster compare to it predecessor WM 6.5. 

To install the application on the device we took the XAP file and deploy it to the device using the XAP Deployment application.

2010-09-12 17h00_12

I was surprised because the application was running smoother on the Device compared to the Emulator (animation, progress bar, etc.).

But when there is some issue related with the development. Like in my case, the application need to get a lot of information from a web service and  I was getting most of the information at the start-up of the application, which was wrong. So i took some time to convert to use a MVVM approach, which increase the performance of the application. So now I'm downloading only the data that i need. Next step, is to apply this technic to every page in the application. That was a great experience, this confirm that the experience on with the emulator in pretty similar.

Also when i was fixing some issues, i was able to test the debugging on the device. If you doesn’t know you can debug you application the same way your doing it on the emulator but directly on the device. So if you have any issue related directly to the device you will be able to fixe it directly with the device.

An important note for the developers who want to deploy the application directly to a device like i did, when you will get a device you need to create an account on the Marketplace to deploy the applications you are creating. Then you will be allowed to unlock 3 devices. What I'm saying by unlocking a device, it unlock the OS so you can deploy. This doesn’t remove the lock from the carrier.

Next step, getting the RTM version of the Developer tools on Thursday, September 16 2010. After what we will have to wait for the real device which will be available for the holidays.

Until then if you have created any Windows Phone 7 application, don’t miss the Deployment clinic in a city near you . You can look at some event date at Canadian Developer Connection.

Regards,
LP