SilverlightShow: Working with Prism 4 Part 3: Composite Command and Pub/Sub Events Comments http://www.silverlightshow.net/ Silverlight articles, Silverlight tutorials, Silverlight videos, Silverlight samples SilverlightShow.net http://www.rssboard.org/rss-specification Argotic Syndication Framework 2008.0.2.0, http://www.codeplex.com/Argotic en-US estoychev@completit.com (Emil Stoychev) Re: Working with Prism 4 Part 3: Composite Command and Pub/Sub Events <p>Hi Deepaprakash, can you give some more information on what is not working?</p> http://www.silverlightshow.net/items/Working-with-Prism-4-Part-3-Composite-Command-and-Pub-Sub-Events.aspx#comment10095 brian.noyes http://www.silverlightshow.net/items/Working-with-Prism-4-Part-3-Composite-Command-and-Pub-Sub-Events.aspx Fri, 29 Nov 2013 15:44:37 GMT Re: Working with Prism 4 Part 3: Composite Command and Pub/Sub Events <p>Hi, </p> <p><br /> </p> <p>The download code is not for working properly. could you please help</p> http://www.silverlightshow.net/items/Working-with-Prism-4-Part-3-Composite-Command-and-Pub-Sub-Events.aspx#comment10093 deepaprakash http://www.silverlightshow.net/items/Working-with-Prism-4-Part-3-Composite-Command-and-Pub-Sub-Events.aspx Fri, 29 Nov 2013 07:35:26 GMT Re: Working with Prism 4 Part 3: Composite Command and Pub/Sub Events <p>Hi Edward,</p> <p>This is a known limitation with the Silverlight tab control and Prism's handling of it. If you take a close look at my sample code I have some workaround code in there for it. Here is a thread that discusses a couple of approaches to solving it as well:</p> <p>http://stackoverflow.com/questions/6044341/silverlight-5-prismtabcontrolregionadapter</p> http://www.silverlightshow.net/items/Working-with-Prism-4-Part-3-Composite-Command-and-Pub-Sub-Events.aspx#comment9419 brian.noyes http://www.silverlightshow.net/items/Working-with-Prism-4-Part-3-Composite-Command-and-Pub-Sub-Events.aspx Fri, 24 May 2013 16:29:32 GMT Re: Working with Prism 4 Part 3: Composite Command and Pub/Sub Events <p>Hi Brian - this is a great series on intro to Prism.  I am on step 5 above, and am getting an error "The property 'ItemContainerStyle' does not exist on the type 'TabControl' in the XML namespace 'http://www.codeplex.com/prism'." and I am not sure how to fix/work around this  Can you help?</p> <p> </p> <p>Thanks,</p> <p>Edward Ellis</p> http://www.silverlightshow.net/items/Working-with-Prism-4-Part-3-Composite-Command-and-Pub-Sub-Events.aspx#comment9413 epellis http://www.silverlightshow.net/items/Working-with-Prism-4-Part-3-Composite-Command-and-Pub-Sub-Events.aspx Thu, 23 May 2013 20:55:54 GMT Re: Working with Prism 4 Part 3: Composite Command and Pub/Sub Events Thanks Brian, that was the solution! (At <a href="http://www.silverlightshow.net/items/WCF-RIA-Services-Part-5-Metadata-and-Shared-Classes.aspx">WCF RIA Services Part 5 - Metadata and Shared Classes</a> ) http://www.silverlightshow.net/items/Working-with-Prism-4-Part-3-Composite-Command-and-Pub-Sub-Events.aspx#comment8341 Nuitari http://www.silverlightshow.net/items/Working-with-Prism-4-Part-3-Composite-Command-and-Pub-Sub-Events.aspx Tue, 31 Jul 2012 14:08:04 GMT Re: Working with Prism 4 Part 3: Composite Command and Pub/Sub Events Do you have [Include] attribute on the relation properties in the entities or their metadata? See my series on RIA services for more details about querying with child objects or collections. http://www.silverlightshow.net/items/Working-with-Prism-4-Part-3-Composite-Command-and-Pub-Sub-Events.aspx#comment8325 brian.noyes http://www.silverlightshow.net/items/Working-with-Prism-4-Part-3-Composite-Command-and-Pub-Sub-Events.aspx Thu, 26 Jul 2012 21:43:42 GMT Re: Working with Prism 4 Part 3: Composite Command and Pub/Sub Events <p>Thanks for the article!</p> <p>I have a problem with the database query returning only null for the foreign keys (Order and Product in Order_Details), I described it in more detail <a href="http://stackoverflow.com/questions/11671317/wcf-ria-entityquery-returns-null-for-foreign-keys" target="_blank">on Stackoverflow</a>. Has someone else had this issue?</p> http://www.silverlightshow.net/items/Working-with-Prism-4-Part-3-Composite-Command-and-Pub-Sub-Events.aspx#comment8324 Nuitari http://www.silverlightshow.net/items/Working-with-Prism-4-Part-3-Composite-Command-and-Pub-Sub-Events.aspx Thu, 26 Jul 2012 18:55:34 GMT Re: Working with Prism 4 Part 3: Composite Command and Pub/Sub Events <p>Dear Brian , your articles very useful for me, i need sample code for that article.</p> <p><br /> </p> http://www.silverlightshow.net/items/Working-with-Prism-4-Part-3-Composite-Command-and-Pub-Sub-Events.aspx#comment8297 gowsar http://www.silverlightshow.net/items/Working-with-Prism-4-Part-3-Composite-Command-and-Pub-Sub-Events.aspx Thu, 12 Jul 2012 09:27:25 GMT Re: Working with Prism 4 Part 3: Composite Command and Pub/Sub Events <p>Brian,</p> <p>Thanks for the speedy response. Please ignore my comment on the inter- module communication. I must have had one of those brain-!*&%( anomalies) when I penned it. </p> <p>I figured out what was wrong in my app. In the Student Property( in the editview model), I had the curly braces incorrectly set (shown in my prior mail). It should be set as shown below. All is fine now. Thanks. </p> <p>As far as future articles, Enhancing this application example with Add , Delete, Cancel changes in addition to Edit( which you have now) in a Master  -Detail ( Like you have now, eg Nwind Customers- Orders ) with Log in /Password  would be appreciated. </p> <p>Best Regards</p> <p>Hari</p> <p>set<br />             {<br />                 if (itsStudent != value )<br />                 {<br />                     if (itsStudent != null)<br />                     {<br />                         itsStudent.PropertyChanged -= OnStudentChanged;<br />                     }<br />                     <br />                     itsStudent = value;<br />                     <br />                     if (itsStudent != null)<br />                     {<br />                         itsStudent.PropertyChanged += OnStudentChanged;<br />                     }<br />                     <br />                     RaisePropertyChanged(() => Student);                <br />                 }</p> http://www.silverlightshow.net/items/Working-with-Prism-4-Part-3-Composite-Command-and-Pub-Sub-Events.aspx#comment7502 HariI15 http://www.silverlightshow.net/items/Working-with-Prism-4-Part-3-Composite-Command-and-Pub-Sub-Events.aspx Sat, 11 Feb 2012 00:00:29 GMT Re: Working with Prism 4 Part 3: Composite Command and Pub/Sub Events <p>Brian,</p> <p>Thanks for the speedy response. Please ignore my comment on the inter- module communication. I must have had one of those brain-!*&%( anomalies) when I penned it. </p> <p>I figured out what was wrong in my app. In the Student Property( in the editview model), I had the curly braces incorrectly set (shown in my prior mail). It should be set as shown below. All is fine now. Thanks. </p> <p>As far as future articles, Enhancing this application example with Add , Delete, Cancel changes in addition to Edit( which you have now) in a Master  -Detail ( Like you have now, eg Nwind Customers- Orders ) with Log in /Password  would be appreciated. </p> <p>Best Regards</p> <p>Hari</p> <p>set<br />             {<br />                 if (itsStudent != value )<br />                 {<br />                     if (itsStudent != null)<br />                     {<br />                         itsStudent.PropertyChanged -= OnStudentChanged;<br />                     }<br />                     <br />                     itsStudent = value;<br />                     <br />                     if (itsStudent != null)<br />                     {<br />                         itsStudent.PropertyChanged += OnStudentChanged;<br />                     }<br />                     <br />                     RaisePropertyChanged(() => Student);                <br />                 }</p> http://www.silverlightshow.net/items/Working-with-Prism-4-Part-3-Composite-Command-and-Pub-Sub-Events.aspx#comment7501 HariI15 http://www.silverlightshow.net/items/Working-with-Prism-4-Part-3-Composite-Command-and-Pub-Sub-Events.aspx Fri, 10 Feb 2012 19:57:52 GMT Re: Working with Prism 4 Part 3: Composite Command and Pub/Sub Events <p>Hi Hari,</p> <p>I'm confused by your comment - this is the article on inter-module communication....</p> <p>As far as your question, I'm not clear on what is not working for you. Is it that the Student property never gets set with selections in the view, or is it that the Title does not get read and used for the tab header when the Student does get set? If the latter, the problem is that you need to RaisePropertyChanged(()=>Title) in the Student setter since that property depends on the value of the Student. That gets the binding to request the value of the property again, and it will pick up the newly set student value.</p> http://www.silverlightshow.net/items/Working-with-Prism-4-Part-3-Composite-Command-and-Pub-Sub-Events.aspx#comment7500 brian.noyes http://www.silverlightshow.net/items/Working-with-Prism-4-Part-3-Composite-Command-and-Pub-Sub-Events.aspx Thu, 09 Feb 2012 22:55:17 GMT Re: Working with Prism 4 Part 3: Composite Command and Pub/Sub Events <p>Hi Brian,</p> <p>I am  really enjoying your articles . The series is very much needed!!  I can't wait for your inter-module communications. I could use your help on a small issue . The problem code is below. The "Student" property defined in the editViewModel class   does not get assigned the "Selected Student". The application runs beautifully but always shows a tab with "empty" title. I would be grateful for any help you can provide</p> <p>Best regards</p> <p>Hari</p> <p>(Code in the StudentListViewModel class)</p> <p>if (!alreadyExists)<br />             {<br />                 StudentEditView editview = new StudentEditView(); <br />                 StudentEditViewModel editVm = new StudentEditViewModel { Student = SelectedStudent };<br />                 editview.DataContext = editVm; <br />                 secondaryContentRegion.Add(editview);<br />                 secondaryContentRegion.Activate(editview);<br /> <br />             }</p> <p>(Code in the StudentEditViewModel class) </p> <p>public Person Student<br />         {<br />             get<br />             {<br />                 return itsStudent;<br />             }<br />             set<br />             {<br />                 if(itsStudent != value)<br />                 {<br />                     if(itsStudent != null)<br />                     {<br />                         itsStudent = value;<br />                         itsStudent.PropertyChanged -= OnStudentChanged;<br />                         itsStudent.PropertyChanged += OnStudentChanged;<br />                         RaisePropertyChanged(() => Student);                  <br />                     }                                    <br />                 }<br />             }<br />         } </p> <p>public string Title<br />         {<br />             get<br />             {      <br />                 return itsStudent != null ? itsStudent.LastName : "Empty";<br />             }<br />             <br />         } </p> <p> </p> <p> </p> http://www.silverlightshow.net/items/Working-with-Prism-4-Part-3-Composite-Command-and-Pub-Sub-Events.aspx#comment7497 HariI15 http://www.silverlightshow.net/items/Working-with-Prism-4-Part-3-Composite-Command-and-Pub-Sub-Events.aspx Wed, 08 Feb 2012 17:07:31 GMT Re: Working with Prism 4 Part 3: Composite Command and Pub/Sub Events <p>In the next one I am going to cover the new navigation features of Prism 4. After that, I plan on one showing how to implement a custom module loader that looks up what modules to load based on the authenticated user (using RIA Services security for the authentication). After that I am open to suggestions.</p> http://www.silverlightshow.net/items/Working-with-Prism-4-Part-3-Composite-Command-and-Pub-Sub-Events.aspx#comment7473 brian.noyes http://www.silverlightshow.net/items/Working-with-Prism-4-Part-3-Composite-Command-and-Pub-Sub-Events.aspx Wed, 01 Feb 2012 15:14:29 GMT Re: Working with Prism 4 Part 3: Composite Command and Pub/Sub Events Brian,  thank you for this great series of articles. I have been wrestling with Prism and this is one of the best practical use introductions I've found.  Keep up the good work.  Any plans for more advanced topics on Prism? http://www.silverlightshow.net/items/Working-with-Prism-4-Part-3-Composite-Command-and-Pub-Sub-Events.aspx#comment7466 jaygittings http://www.silverlightshow.net/items/Working-with-Prism-4-Part-3-Composite-Command-and-Pub-Sub-Events.aspx Tue, 31 Jan 2012 20:30:51 GMT