prism

DelegateCommand CanExecute not firing for UIControls placed in different region using Prism

Hi, I'm using WPF-Prism and I'm struggling with a DelegateCommand that is not activating a button that is situated in a different region (defined in Prism). Example: HomeTab module: I have a HomeTab module with a region for adding buttons (using Fluent ribbon) relative to the active application. Application module: I create a button vi...

How to implement smart parts Prism

Hi, I am unable to find a way to implement Smart Parts like SCSF, in wpf prism, can any one suggest a way how to do it, links, articles, appriciated. Thank you in advance, :) ...

Smart client Winform vs MVVM + Prism

Hi, I am new to desktop applications, so please bare with me if this sounds very basic question. The question is, is Windows forms Simart Client is a legacy thing now? and to be replaced by Prism (and/or MVVM)? Should I bother to learn about Smart Client? Another question which might be related to is that what are the performance diffe...

How to dynamically discover all XAML files in all modules in a Silverlight prism app.

Is there an easy way to dynamically discover all the XAMLs files within all the currently loaded modules (specifically of a Silverlight Prism application)? I am sure this is possible, but not sure where to start. This has to occur on the Silverlight client: We could of course parse the projects on the dev machine, but that would reduce ...

Prism+MEF: delayed a service export from prism-module

Hi, I have an app based on Prism (v4 ctp) and MEF. The app has a service IService1. I want this service implementation was exported by some module (not just discovered by MEF) public interface IService1 {} public class Service1Impl: IService1 {} Service1Impl doesn't have ExportAttribute. This' because I want to create the implementati...

Silverlight Prism: How to change the shell layout for a new page?

Hi There, I am new to Silverlight/Prism, so not sure how a new layout page would be rendered. I've got the Shell working like a master page, but I want to have several pages in the application with a different layout master. So, how do I get another (shell) or layout page to arrange different regions? Thanks for any conceptual feedback...

Why is my wpf grid not being contained in its container?

I have a user control and within it I have two controls: 1) a search criteria control (custom user control) and 2) a Telerik RadGridView. Apart from that I have a window that is the shell for my application and in it exists three regions. When this window opens I click a button and the user control mentioned above gets inserted into on...

How to programmatically create MenuItems (with a header) in a dynamic menu

I apologize for the length of this question - there is a question in here (at the end!), but I wanted to make sure the source code was explicit. Anyway. [Edit #2] - question title changed to more accurately reflect the... question. [Edit] - I've updated some more of the history as to how I ended up at the design / code that I did here...

Information on migrating from Client/Server to ASP.net web parts

I have had the question posed at my work that, since we are planning to eventually move to Sharepoint 2010 for most of our Development, and since Sharepoint 2010 supports asp.net web parts, should we start moving all of our new development to be exclusively asp.net web parts? It was also asked how prism factors into all of this. So my ...

RIA Service initialization problem

Hello, I have a problem with RIA services. Some times (not always) I get an InvalidOperationException with the message: "EntityTypes has already been initialized" The error comes from the generated file but I don't know how to resolve this issue. Google brings out only 2 results which are not very helpfull. Does anybody know what I co...

What should I use in Prism- MEF or Unity?

Found several good(related) questions here and here but all are nearly a year old. I will like to know in the current context of Prism development what is better or at least scenario where each is better. ...

Prism IDataErrorInfo validation with DataAnnotation on ViewModel Entities

Hi, I'm implementing data validation in WPF using the Prism MVVM framework. I'm using clean data Entities in the ViewModel which are being bound to the presentation layer. <TextBox Text="{Binding User.Email, ValidatesOnDataErrors=True, UpdateSourceTrigger=PropertyChanged}" /> I've implemented a generic implementation of IDataErrorIn...

How to show a login screen before loading the actual shell in Prism framework

In my application I want to show a login screen first, if the login is successful only then I want to show what is known as a Shell. How would you structure a simple application that first authenticates the user via some login screen and then opens up the main window that acts as container for further module? ...

Changing the size of a region in Prism

This is perhaps a silly question, but I can't seem to find out how to do this. I have a Silverlight app using Prism's regions, and I have a requirement for an 'expand'-type button inside one of my views. When the user clicks that button, I need the view to grow larger. How do I change the size of my region dynamically, like this? I...

Prism: Prevent executing a command in duplicate views using IActiveAware?

Hi There, I have a Silverlight application that has three regions that will host the same Views. What I want to know is, how may I create a zoom control for each of the views, without zooming all of the views (assuming the zoom action is using Prism Commands). Would IActiveAware be the right approach? ...

Accessing external static resources placed in different assembly and XAP

My prism based silveright application is divided into multiple xaps to reduce initial download size and support multi tenant application. However, I cannot access the resource dictionaries defined in external assembly (i.e. the resource .xaml file is part of an assembly that complies/ is copied into a different xap) Any suggestions ? b...

WPF, MVVM and Prism modularity

I am still learning to use MVVM and Prism and have some general questions: I have a grid in my view. Lets say I have a button that when I click I want it to auto size the grid columns. Where would that code go? Resizing grid columns is a view thing and the view model shouldn't know about it. So in this case would I be adding the bu...

Accessing unity container in view model class

I have a shell which looks like toolbar and defines my main region (a wrap panel). What I need to do is be able to add widgets to the shell and when a widget is clicked, a new window (view) is opened. Below is what I have so far: I created a module class which adds a view to the main region: public class MyModule : IModule { protec...

How individual modules/views behave in Prism (composite application pattern for WPF)

This may come off as a totally n00b question as I know very little about PRISM at all yet, but let's imagine I have a hypothetical situation of a composite application consisting of 3 controls: Control A (a chart), Control B (a table) and Control C (a calculator). Are all of these controls running on the same UI thread? For example if ...

run all modules of a catalog (prism)

hello, i'm using the desktop library of prism. what i want is to get modules in a directory and then, run them. I do like that: DirectoryModuleCatalog catalog = new DirectoryModuleCatalog(); catalog.ModulePath = @"C:\Users\Raph\Documents\Visual Studio 2010\Projects\LibraryLoad\LibraryLoad\Modules"; I checked, the modules are loaded ...