Wednesday, March 9, 2011

Some simple steps to convert ASP.NET application to Silverlight application

Sometime you may be asked to look at the possiblity of converting the ASP.NET application to Silverlight application. Trust me, there are no hard and fast rules to migrating ASP.NET to Silverlight due to various reasons;
  1. Silverlight runs in client-side; ASP.NET runs in the server-side. This means, you will not be able to use as much as functionalities available from server-side.
  2. Application Life Cycle is entirely different for Silverlight and ASP.NET. You need to familiarize yourselves first before starting to work on silverlight.

But, somehow I managed to find some steps which will ease the ASP.NET to Silverlight migration;
  1. Find the equivalent controls for ASP.NET controls in Silverlight
  2. Convert the .aspx pages to .xaml files
  3. Define the Page navigation in App.xaml.cs file (bit difficult to do)
  4. Silverlight support very few assembly references. Migrate the .aspx.cs code .xaml.cs code accordingly.
  5. If you encounter some assembly references breaking, convert those functionalities to WCF service. Good thing about silverlight is that, it supports communication with WCF service with some limitations (no WS-Security)
  6. Silverlight follows MVVM pattern, if you application built around MVVM or can be easily upgraded to MVVM pattern, you can migrate your ASP.NET application to Silverlight application at ease...

I will update this post, If I manage to find some other tweaks and tricks in converting ASP.NET to Siliverlight.

1 comment:

  1. Good to know this information about converting asp.net to silverlight application. useful information.

    ASP to ASP.Net Migration

    Convert ASP to ASP.Net

    ReplyDelete