MVC archt. in Silverlight Application - silverlight

I want to implement MVC arch. in silverlight application.
I have the following questions:
Is silverlight version and MVC architecture is dependent? for example: silverlight 4 is required for building the silverlight mvc application
Can any one give any example or sample project link or code, so that i can refer for building my own?
Thanks in Advance

In Silverlight there is more common to use MVVM architecture then MVC. SL has some features that allows easily use MVVM in it.
Useful links:
Model-View-ViewModel In Silverlight 2 Apps
Using the MVVM Pattern in Silverlight Applications
Good Silverlight-MVVM Practice Example
5 Minute Overview of MVVM in Silverlight

Related

what's a framework used to build a wpf project?

i had an interview yesterday. i'm new with the wpf technology and they asked me what's the framework i used to build my project? (it's not .Net framework)
it's smth like best practices.
have you an idea about this?
There are several MVVM frameworks to build WPF applications like the following:
Caliburn Micro
Prism
MVVM Light Toolkit
I believe that for other than trivial applications you should use a MVVM framework.

Creating an application in N-Tier in Silverlight

I want an demo example for an N-Tier application in Silverlight so that using this example as a reference i can develop my application which is also to be developed in same manner.
I have designed an application in Silverlight using N-tier but there are a lot of issues and i think m not using the right method to do it
Can anyone please provide me with such demo example or a link.It would be great if i can get a video tutorial.
Thankss
Start here: The MVVM Pattern make sure you make it through to the WCF RIA Services chapter.

Tips on creating a plug-in architecture for WPF

I'm making the switch from Winforms to WPF. In Winforms I have a plug-in architecture where a user control is hosted in a Winform. Does anyone have any suggestions on creating a plug-in architecture for WPF? I want to rally the forces of the developers in my community to further extend my products so I believe in an extensible framework for my apps. I'm just starting WPF so I'm not sure what the best way is to go about this.
Thank you.
Have a look into the Managed Extensibility Framework
You might find the article about modular architecture for WPF applications interessting as well. Please not that a plugin is the same thing as a module in this aspect.
The Information Manager sample application of the WPF Application Framework (WAF) shows how to apply these concepts to create a plug-in architecture. It uses MEF as well to discover and load the Plug-Ins.

Silverlight 4: Prism still usable?

Would you still use Prism with SL4, even when Silverlight 4 already supports commanding, e.g. MVVM concept?
Are there features in Prism which can be used and improve design of Silverlight 4 application?
Modules - to structure the application (with an option of dynamically loading modules when needed
RegionManager - to deal with assembling UI (layout) from components from different independent modules
EventAggregator - to deal with cross-module communication (e.g. loosely coupled communication)
On a general note, sticking to the Prism pattern forces an additional level of structure on your Silverlight development. This is especially of benefit to dev teams, more than individuals, as that work can be cleanly partitioned.
The latest Prism 4 went to beta on August 2nd and now adds MEF support (Managed Extensibility Framework) to the other features PL mentions.
MEF is great for building a plug-in based framework. As an example of what it can do the Visual Studio IDE itself uses MEF to implement pretty much everything as a plug-in. Now you can do the same sort of dynamic plugins in Silverlight!
We are currently doing Silverlight Prism development with the previous 2.2. release, but will move over to Prism 4 as soon as it is out of Beta.

Silverlight 2 UI pattern

I have to build small (for now) admin app in Silverlight2, and would like to use some pattern for binding UI with my BL/DAL.
I found view-model-viewmodel and mvp/mvc patterns, where first one (V/M/VM) is specially suited for WPF apps, because it uses rich capabilities of WPF data-binding options. What do you suggest? Can you write simple example of V/M/VM for SL2?
Nikhil Kothari has a great set of examples (with code) on M-V-VM in Silverlight as well as a framework built with some very nice extra features. You should definitely check them out.
M-V-VM in Silverlight
The Patterns & Practices group at Microsoft has put together some guidance around doing WPF and Silverlight applications.
You might want to look at CSLA.NET for Silverlight. I've heard good things about it but haven't gotten around to try it yet myself.
CSLA .NET for Silverlight is a subset
of CSLA .NET targeted at the
Silverlight platform. CSLA .NET for
Silverlight offers nearly all the
benefits of CSLA .NET on Silverlight,
including data binding, validation,
business rules, authorization, n-level
undo and persistence.
The result is that CSLA .NET for
Silverlight enables the creation of a
rich object-oriented business layer
running on the Silverlight client,
that can transparently communicate
with CSLA .NET objects running on the
web and application servers.
Silverlight has also very powerful data-binding, so there is no problem with that.
The missing piece in Silverlight that affects more to the Model-View-ViewModel pattern is that it doesn’t implements commands like WPF. Here is an article by Josh Smith that reproduces the command pattern of WPF in Silverlight.
Shawn Wildermuth of Wildermuth.com wrote an article about the MV-VM Pattern, check it out, here is the link of the article "Model-View-ViewModel In Silverlight 2 Apps"
Norwegian developer Gjøran had a very nice presentation/demo at MSDN Live about writing business apps in WPF. Really it was about using Presentation Model with Silverlight/WPF. Have a look at the source code from this article on his blog (sorry, the slides are in Norwegian only). Presentation Model + silverlight 2 rocks!!!

Resources