locked
WPF to HTML Can it be done? RRS feed

  • Question

  • Our company is investigating the possibility of moving from WPF to HTML5 for our application. About 150 screens! The WPF application implements the application using MVVM with the following layers:

    1. View

    2. ViewModel

    3. DataService

    4. Model

    So pretty standard approach although not sure everyone splits the data service out that accesses the Model....

    We really want to use as much of the current code as we can. We plan to develop the application in ASP.NET MVC 4. 

    My questions:

    1. Can we move the code or call the ViewModel code from the Controller to supply all the business logic that has already been coded? We are naturally using entities that we bind to the the XAML... so we will need to put Knockout code to do the data binding. So basically we need to write tons of code for the data binding?

    2. Of course we are going to run into all kinds of things that we are doing in VM's that are going to be issues. Like MessageBoxes or InputBoxes or messaging between view models. Big issues right?

    By the way we decided to move to HTML just because we would like to have our product on many more devices and updating the product can be a tough at times. 


    Thanks, Aaron

    Saturday, December 15, 2012 6:27 PM

Answers

  • Hi Aaron,

    The Windows Store apps Forums are for discussion of writing Windows Store apps. For questions about asp.net please post in the appropriate forums on http://asp.net .

    If you want to convert a WPF app to a Windows Store app then I would recommend using Xaml rather than HTML since you already have Xaml knowledge and can likely leverage more of your existing .Net code. Another option would be to expose your Model as a Windows Runtime Component and then write the View as HTML.

    --Rob

    Sunday, December 16, 2012 9:56 AM