Notes on Silverlight.Desk to Silverlight.WP7 migration

“One mans journey converting http://FromTheMalverns/Spot from a Silverlight Desktop App to a Windows Mobile 7 App hosted in the market place.


UPDATE: Having now caught up with some of the MIX sessions I would advise that the best way to manage a Desktop SIlverlight and WP7 App is together, in the same solution file using shared code.  For more information on  this check out sessions CL16 and CL17 from Mix10 available here.

Methodology Steps:

  1. I created an empty WP7 app using Visual Studio Express for WP7
  2. Copy and paste all items from desktop app (in the file system)
  3. Imported all the desktop items into the WP7 app
  4. Refactored all the namespaces (not strictly necessary if you decide to keep the same namespace)

Minor Issues I hit:

  • I had to delete the target elements from the Hyperlink controls as these are not supported in WP7 (see below)
  • I don’t have as many pixels as I though (I designed for 800×480 but the app is being cropped in the emulator?  (turns out I had a margin set incorrectly!)
  • Sounds not playing?


image* While the links remained after removal of he target attribute when selecting them in the emulator I get the following message (would have been nice top get the message in landscape mode, no doubt we will by the time we get to prod)

Other Issues


  • I added an extra line to let the phone know that I only support landscape Mode (SupportedOrientations= Supportedorientations.Landscape)
  • I’ve added a call top the VibrateController for a quick ‘buzz’ each time a difference is found.
  • Obviously the design of the app predated the guidelines and opportunities that the phone platform provides.  (I plan on reviewing the design once I have the functionality sorted out).


And that was enough to get the app up and running on my (emulated) phone!!

Spotwp71Huzzah!  But wait.  I move my finger on the phone emulator, the magnifying glass moves CHECK.  I find a difference and tap with a second finger OOPS nothing.So question now is:

  • Does the emulator support multitouch? (My Laptop supports 2 touch points)
  • Is my code for multitouch incorrect? (it worked on my Silverlight desktop OK)

I will update this post when I have the answer.

And here is that answer from the excellent free Peltzoid book:

Touch Events in Silverlight rlight 3, you know about the Touch.FrameReported event. In Windows Phone 7 Series programming, that event has become obsolete. ManipulationStarted, ManipulationInertiaStarting, ManipulationDelta, and ManipulationCompleted. These events are so sophisticated in incorporating concepts of velocity and inertia that they really acquire a ManipulationStarted just to detect … 

Apart from that issue … very impressed so far!


2 thoughts on “Notes on Silverlight.Desk to Silverlight.WP7 migration

  1. Great items from you, man. I’ve take into account your stuff previous to and you are simply extremely wonderful. I actually like what you’ve got right here, certainly like what you’re stating and the best way through which you say it. You are making it enjoyable and you still take care of to stay it smart. I can not wait to read much more from you. This is actually a great web site.

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s