<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="https://www.dotnetzone.gr:443/cs/utility/FeedStylesheets/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/"><channel><title>Πρώτα Βήματα - Desktop Applications</title><link>https://www.dotnetzone.gr:443/cs/forums/80/ShowForum.aspx</link><description>Θέματα για όσους φτιάχνουν τα πρώτα τους Desktop Applications σε .NET Framework</description><dc:language>el</dc:language><generator>CommunityServer 2.1 SP3 (Build: 20423.1)</generator><item><title>Απ: Interact to mainWindow ListView</title><link>https://www.dotnetzone.gr:443/cs/forums/thread/62814.aspx</link><pubDate>Mon, 31 Jan 2011 05:20:33 GMT</pubDate><guid isPermaLink="false">2622095e-976c-431a-859e-16783ec7ecd7:62814</guid><dc:creator>KelMan</dc:creator><slash:comments>0</slash:comments><comments>https://www.dotnetzone.gr:443/cs/forums/thread/62814.aspx</comments><wfw:commentRss>https://www.dotnetzone.gr:443/cs/forums/commentrss.aspx?SectionID=80&amp;PostID=62814</wfw:commentRss><description>&lt;P&gt;Και όμως Δήμο, αν υλοποιήσεις winforms με το Model View Presenter pattern, πολλά από αυτά βρίσκουν εφαρμογή κι εκεί...&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description></item><item><title>Απ: Interact to mainWindow ListView</title><link>https://www.dotnetzone.gr:443/cs/forums/thread/62811.aspx</link><pubDate>Mon, 31 Jan 2011 04:54:15 GMT</pubDate><guid isPermaLink="false">2622095e-976c-431a-859e-16783ec7ecd7:62811</guid><dc:creator>dimos.homatas</dc:creator><slash:comments>0</slash:comments><comments>https://www.dotnetzone.gr:443/cs/forums/thread/62811.aspx</comments><wfw:commentRss>https://www.dotnetzone.gr:443/cs/forums/commentrss.aspx?SectionID=80&amp;PostID=62811</wfw:commentRss><description>Καμία σχέση με τα winforms τελικά&amp;nbsp;&lt;img src="http://www.dotnetzone.gr/cs/emoticons/emotion-2.gif" alt="Big Smile" /&gt;</description></item><item><title>Απ: Interact to mainWindow ListView</title><link>https://www.dotnetzone.gr:443/cs/forums/thread/62807.aspx</link><pubDate>Mon, 31 Jan 2011 03:33:42 GMT</pubDate><guid isPermaLink="false">2622095e-976c-431a-859e-16783ec7ecd7:62807</guid><dc:creator>StrouMfios</dc:creator><slash:comments>0</slash:comments><comments>https://www.dotnetzone.gr:443/cs/forums/thread/62807.aspx</comments><wfw:commentRss>https://www.dotnetzone.gr:443/cs/forums/commentrss.aspx?SectionID=80&amp;PostID=62807</wfw:commentRss><description>Σίγουρα θα δοκίμαζα να τελειώσω αυτό που έχω ξεκινήσει με τον υπάρχων framework πριν έπαιρνα την μεγάλη απόφαση της αλλαγής :)&lt;div&gt;&lt;br&gt;&lt;/div&gt;&lt;div&gt;Έχω ήδη στείλει μήνυμα στον Karl και περιμένω&amp;nbsp;&lt;img src="http://www.dotnetzone.gr/cs/emoticons/emotion-2.gif" alt="Big Smile" /&gt;&lt;/div&gt;&lt;div&gt;&lt;br&gt;&lt;/div&gt;</description></item><item><title>Απ: Interact to mainWindow ListView</title><link>https://www.dotnetzone.gr:443/cs/forums/thread/62805.aspx</link><pubDate>Mon, 31 Jan 2011 03:15:09 GMT</pubDate><guid isPermaLink="false">2622095e-976c-431a-859e-16783ec7ecd7:62805</guid><dc:creator>KelMan</dc:creator><slash:comments>0</slash:comments><comments>https://www.dotnetzone.gr:443/cs/forums/thread/62805.aspx</comments><wfw:commentRss>https://www.dotnetzone.gr:443/cs/forums/commentrss.aspx?SectionID=80&amp;PostID=62805</wfw:commentRss><description>&lt;P&gt;Μην πηδάς έτσι εύκολα από framework σε framework &lt;img src="http://www.dotnetzone.gr/cs/emoticons/emotion-2.gif" alt="Big Smile" /&gt; Παίδεψέ το λίγο το πράγμα! Στείλε μια ερώτηση στον Karl, δες λίγο αν το IDialogService παρέχει callback functionality.&lt;/P&gt;
&lt;P&gt;To In the box MVVM training είναι μια χαρά για να μάθεις το MVVM και είναι πολύ σημαντικό να το μάθεις γιατί έτσι θα σου έρθουν ιδέες μελλοντικά στα διάφορα προβλήματα που θα συναντήσεις. &lt;/P&gt;
&lt;P&gt;Το MVVM Light είναι ένα έτοιμο πράγμα, ωστόσο μπορείς να κλέψεις από αυτό το messaging&amp;nbsp;functionality. To Locator pattern μπορεί να υλοποιηθεί ανεξάρτητα και δεν χρειάζεται υποχρεωτικά το MVVM Light.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description></item><item><title>Απ: Interact to mainWindow ListView</title><link>https://www.dotnetzone.gr:443/cs/forums/thread/62804.aspx</link><pubDate>Mon, 31 Jan 2011 03:02:55 GMT</pubDate><guid isPermaLink="false">2622095e-976c-431a-859e-16783ec7ecd7:62804</guid><dc:creator>StrouMfios</dc:creator><slash:comments>0</slash:comments><comments>https://www.dotnetzone.gr:443/cs/forums/thread/62804.aspx</comments><wfw:commentRss>https://www.dotnetzone.gr:443/cs/forums/commentrss.aspx?SectionID=80&amp;PostID=62804</wfw:commentRss><description>To IDialogSerice και πολλά άλλα που έχω χρησιμοποιήσει στο app τα έχω πάρει απο ένα project (&lt;a href="http://karlshifflett.wordpress.com/2010/11/07/in-the-box-ndash-mvvm-training/"&gt;http://karlshifflett.wordpress.com/2010/11/07/in-the-box-ndash-mvvm-training/&lt;/a&gt;).&lt;div&gt;Όχι δεν θεωρώ οτι είναι πολύ φασαρία αυτά που μου είπες. Εϊναι απλα ένας σωστός τρόπος και απλά πρέπει να τον μάθω και να τον συνηθίσω.&lt;/div&gt;&lt;div&gt;&lt;br&gt;&lt;/div&gt;&lt;div&gt;Οπότε σε γενικές γραμμές μου προτείνεις να χρησιμοποιήσω το MVVM Light.&lt;/div&gt;&lt;div&gt;Θα το κατεβάσω, θα το δοκιμάσω και ελπίζω να μου διαλευκάνει λίγο το τοπίο.&lt;/div&gt;&lt;div&gt;&lt;br&gt;&lt;/div&gt;&lt;div&gt;Σε ευχαριστώ πολύ για την βοήθειά σου.&lt;/div&gt;&lt;div&gt;&lt;br&gt;&lt;/div&gt;</description></item><item><title>Απ: Interact to mainWindow ListView</title><link>https://www.dotnetzone.gr:443/cs/forums/thread/62801.aspx</link><pubDate>Mon, 31 Jan 2011 02:36:43 GMT</pubDate><guid isPermaLink="false">2622095e-976c-431a-859e-16783ec7ecd7:62801</guid><dc:creator>KelMan</dc:creator><slash:comments>0</slash:comments><comments>https://www.dotnetzone.gr:443/cs/forums/thread/62801.aspx</comments><wfw:commentRss>https://www.dotnetzone.gr:443/cs/forums/commentrss.aspx?SectionID=80&amp;PostID=62801</wfw:commentRss><description>&lt;P&gt;Το IDialogService εσύ το έχεις γράψει ή είναι από κάποιο framework? Τυπικά θα πρέπει να έχει κάποιο callback ώστε να κάνεις hook το function που θες να κληθεί μόλις κλείσει το dialog. &lt;/P&gt;
&lt;P&gt;Πάντως γενικά το implementation δεν μου αρέσει γιατί έχει ένα πρόβλημα: Το MainWindowViewModel&amp;nbsp;γνωρίζει για την ύπαρξη του AddItems view. Τυπικά, το ViewModel δεν πρέπει να ξέρει ούτε καν για το View που το χρησιμοποιεί, πόσο μάλλον για ένα άλλο τρίτο View. Υπάρχει δηλαδή ένα dependency που δεν θα έπρεπε να υπάρχει το οποίο οδηγεί σε δυσκολία στο testing,&amp;nbsp;αφαιρεί&amp;nbsp;μελλοντική ευελιξία για&amp;nbsp;αναδιάρθρωση των&amp;nbsp;Views/ViewModels,&amp;nbsp;ακόμη και σε memory leaks. &lt;/P&gt;
&lt;P&gt;Καλύτερη υλοποίηση είναι ένας μηχανισμός messaging. Η λογική του messaging μηχανισμού είναι η εξής: Κάποιοι μεταδίδουν μηνύματα και κάποιοι αποφασίζουν να ακούν για τα μηνύματα που τους ενδιαφέρουν. Το Main ViewModel λοιπόν, μεταδίδει ένα μήνυμα ότι ο χρήστης ζήτησε να ανοίξει το dialog μαζί με κάποιες παραμέτρους για το τι χρειάζεται αυτό το dialog. Εκεί τελειώνει η δουλειά του. Αυτό το μήνυμα το παίρνει οποιοσδήποτε έχει δηλώσει ενδιαφέρον (πχ o Locator που λέγαμε προηγουμένως) και ανοίγει το dialog. Το dialog με τη σειρά του στο τέλος μεταδίδει ένα μήνυμα που λέει ότι έχει τελειώσει και δίνει ως παράμετρους τις αλλαγές. Ο&amp;nbsp;Locator&amp;nbsp;ξαναλμβάνει το μήνυμα και σηκώνει το Main ViewModel που χειρίζεται τις αλλαγές. Με αυτόν τον τρόπο τα δύο ViewModels είναι ανεξάρτητα και καθώς τα μηνύματα αυτά που λέμε παίζουν με weak references δεν υπάρχει κίνδυνος για memory leaks.&lt;/P&gt;
&lt;P&gt;Όλα αυτά θα τα βρεις υλοποιημένα στο MVVM Light ωστόσο μιας και είμαστε στα πρώτα βήματα μην χρησιμοποιήσεις απλά το framework αλλά δες του source για να καταλάβεις πώς δουλεύει. &lt;/P&gt;
&lt;P&gt;Έχεις πέσει σε ένα από τα κλασικά προβλήματα που συναντάς όταν παίζεις με MVVM. Αν θεωρείς ότι είναι πολλή φασαρία για τις αλλαγές που σου προτείνω ή ότι δεν θα κάνεις ποτέ testing οπότε δεν είναι μεγάλο κακό το να σηκώνεις View μέσα από το ViewModel, τότε μπορείς να βάλεις το child view να κάνει raise ένα event στο οποίο θα απαντά το parent view ωσόσο κράτησε σρο μυαλό σου ότι αυτή η τεχνική δεν ενδείκνυται.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description></item><item><title>Απ: Interact to mainWindow ListView</title><link>https://www.dotnetzone.gr:443/cs/forums/thread/62798.aspx</link><pubDate>Mon, 31 Jan 2011 01:41:47 GMT</pubDate><guid isPermaLink="false">2622095e-976c-431a-859e-16783ec7ecd7:62798</guid><dc:creator>StrouMfios</dc:creator><slash:comments>0</slash:comments><comments>https://www.dotnetzone.gr:443/cs/forums/thread/62798.aspx</comments><wfw:commentRss>https://www.dotnetzone.gr:443/cs/forums/commentrss.aspx?SectionID=80&amp;PostID=62798</wfw:commentRss><description>Παρακάτω παραθέτω τον κώδικα&lt;div&gt;&lt;br&gt;&lt;/div&gt;&lt;div&gt;MainWindow.xaml&lt;/div&gt;&lt;div&gt;&lt;table border="0" cellpadding="0" cellspacing="0" width="100%" style="background-color:#f2f2f2;border:solid 1px #e5e5e5;"&gt;&lt;tr style="vertical-align:top;line-height:normal;"&gt;&lt;td style="width:40px;text-align:right;"&gt;&lt;pre style="font-family:courier new;font-size:11px;color:gray;margin:0px;padding:2px;border-right:solid 1px #e7e7e7;"&gt;1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
 &lt;/pre&gt;&lt;/td&gt;&lt;td&gt;&lt;pre style="margin:0px;padding:2px;padding-left:8px;"&gt;&lt;span style="color:Black;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:Maroon;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;Window&lt;/span&gt; &lt;span style="color:Red;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;x:Class&lt;/span&gt;&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;="ToDoListTest.MainWindow"&lt;/span&gt;
        &lt;span style="color:Red;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;xmlns&lt;/span&gt;&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;="http://schemas.microsoft.com/winfx/2006/xaml/presentation"&lt;/span&gt;
        &lt;span style="color:Red;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;xmlns:x&lt;/span&gt;&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;="http://schemas.microsoft.com/winfx/2006/xaml"&lt;/span&gt;
        &lt;span style="color:Red;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;xmlns:local&lt;/span&gt;&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;="clr-namespace:ToDoListTest.ViewModels"&lt;/span&gt;
        &lt;span style="color:Red;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;Title&lt;/span&gt;&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;="MainWindow"&lt;/span&gt; &lt;span style="color:Red;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;Height&lt;/span&gt;&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;="350"&lt;/span&gt; &lt;span style="color:Red;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;Width&lt;/span&gt;&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;="525"&lt;/span&gt;&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;&amp;gt;&lt;/span&gt;
    
    &amp;lt;Window.DataContext&amp;gt;
        &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:Maroon;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;local:MainWindowViewModel&lt;/span&gt; &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;/&amp;gt;&lt;/span&gt;
    &amp;lt;/Window.DataContext&amp;gt;
    
    &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:Maroon;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;Grid&lt;/span&gt;&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;&amp;gt;&lt;/span&gt;
        &amp;lt;Grid.ColumnDefinitions&amp;gt;
            &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:Maroon;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;ColumnDefinition&lt;/span&gt; &lt;span style="color:Red;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;Width&lt;/span&gt;&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;="133*"&lt;/span&gt; &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;/&amp;gt;&lt;/span&gt;
            &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:Maroon;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;ColumnDefinition&lt;/span&gt; &lt;span style="color:Red;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;Width&lt;/span&gt;&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;="370*"&lt;/span&gt; &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;/&amp;gt;&lt;/span&gt;
        &amp;lt;/Grid.ColumnDefinitions&amp;gt;
        &amp;lt;Grid.RowDefinitions&amp;gt;
            &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:Maroon;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;RowDefinition&lt;/span&gt; &lt;span style="color:Red;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;Height&lt;/span&gt;&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;="60*"&lt;/span&gt; &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;/&amp;gt;&lt;/span&gt;
            &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:Maroon;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;RowDefinition&lt;/span&gt; &lt;span style="color:Red;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;Height&lt;/span&gt;&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;="251*"&lt;/span&gt; &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;/&amp;gt;&lt;/span&gt;
        &amp;lt;/Grid.RowDefinitions&amp;gt;
        &amp;lt;ListView Grid.Row="1" Height="239" HorizontalAlignment="Left" Margin="12,0,0,0" Name="ToDoItemsLV" VerticalAlignment="Top" Width="479" Grid.ColumnSpan="2" ItemsSource="{Binding ItemResults}"&amp;gt;
            &amp;lt;ListView.View&amp;gt;
                &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:Maroon;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;GridView&lt;/span&gt;&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;&amp;gt;&lt;/span&gt;
                    &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:Maroon;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;GridViewColumn&lt;/span&gt; &lt;span style="color:Red;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;Width&lt;/span&gt;&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;="100"&lt;/span&gt; &lt;span style="color:Red;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;Header&lt;/span&gt;&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;="Name"&lt;/span&gt; &lt;span style="color:Red;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;DisplayMemberBinding&lt;/span&gt;&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;="{Binding Path=Name}"&lt;/span&gt;&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;&amp;gt;&lt;/span&gt;
                    &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:Maroon;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;GridViewColumn&lt;/span&gt; &lt;span style="color:Red;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;Width&lt;/span&gt;&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;="200"&lt;/span&gt; &lt;span style="color:Red;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;Header&lt;/span&gt;&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;="Description"&lt;/span&gt; &lt;span style="color:Red;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;DisplayMemberBinding&lt;/span&gt;&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;="{Binding Path=Description}"&lt;/span&gt;&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;&amp;gt;&lt;/span&gt;
                    &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:Maroon;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;GridViewColumn&lt;/span&gt; &lt;span style="color:Red;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;Width&lt;/span&gt;&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;="100"&lt;/span&gt; &lt;span style="color:Red;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;Header&lt;/span&gt;&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;="Date To Act"&lt;/span&gt; &lt;span style="color:Red;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;DisplayMemberBinding&lt;/span&gt;&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;="{Binding Path=DateToAct}"&lt;/span&gt;&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;&amp;gt;&lt;/span&gt;
                    &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:Maroon;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;GridViewColumn&lt;/span&gt; &lt;span style="color:Red;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;Width&lt;/span&gt;&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;="50"&lt;/span&gt; &lt;span style="color:Red;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;Header&lt;/span&gt;&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;="Status"&lt;/span&gt; &lt;span style="color:Red;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;DisplayMemberBinding&lt;/span&gt;&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;="{Binding Path=Status}"&lt;/span&gt;&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;&amp;gt;&lt;/span&gt;
                &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:Maroon;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;GridView&lt;/span&gt;&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;&amp;gt;&lt;/span&gt;
            &amp;lt;/ListView.View&amp;gt;
        &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:Maroon;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;ListView&lt;/span&gt;&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;&amp;gt;&lt;/span&gt;
        &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:Maroon;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;Button&lt;/span&gt; &lt;span style="color:Red;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;Content&lt;/span&gt;&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;="Add New Item"&lt;/span&gt; &lt;span style="color:Red;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;Width&lt;/span&gt;&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;="100"&lt;/span&gt; &lt;span style="color:Red;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;Height&lt;/span&gt;&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;="30"&lt;/span&gt; &lt;span style="color:Red;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;Margin&lt;/span&gt;&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;="0,15,16,15"&lt;/span&gt; &lt;span style="color:Red;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;HorizontalAlignment&lt;/span&gt;&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;="Right"&lt;/span&gt; &lt;span style="color:Red;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;Command&lt;/span&gt;&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;="{Binding AddNewItem}"&lt;/span&gt;&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;&amp;gt;&lt;/span&gt;
    &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:Maroon;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;Grid&lt;/span&gt;&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;&amp;gt;&lt;/span&gt;
&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:Maroon;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;Window&lt;/span&gt;&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;&amp;gt;&lt;/span&gt;&lt;/span&gt;&lt;/pre&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/table&gt;&lt;br&gt;&lt;/div&gt;&lt;div&gt;&lt;br&gt;&lt;/div&gt;&lt;div&gt;AddItems.Xaml&lt;/div&gt;&lt;div&gt;&lt;table border="0" cellpadding="0" cellspacing="0" width="100%" style="background-color:#f2f2f2;border:solid 1px #e5e5e5;"&gt;&lt;tr style="vertical-align:top;line-height:normal;"&gt;&lt;td style="width:40px;text-align:right;"&gt;&lt;pre style="font-family:courier new;font-size:11px;color:gray;margin:0px;padding:2px;border-right:solid 1px #e7e7e7;"&gt;1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
 &lt;/pre&gt;&lt;/td&gt;&lt;td&gt;&lt;pre style="margin:0px;padding:2px;padding-left:8px;"&gt;&lt;span style="color:Black;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:Maroon;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;Window&lt;/span&gt; &lt;span style="color:Red;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;x:Class&lt;/span&gt;&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;="ToDoListTest.AddItems"&lt;/span&gt;
        &lt;span style="color:Red;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;xmlns&lt;/span&gt;&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;="http://schemas.microsoft.com/winfx/2006/xaml/presentation"&lt;/span&gt;
        &lt;span style="color:Red;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;xmlns:x&lt;/span&gt;&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;="http://schemas.microsoft.com/winfx/2006/xaml"&lt;/span&gt;
        &lt;span style="color:Red;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;Title&lt;/span&gt;&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;="Add New Item"&lt;/span&gt; &lt;span style="color:Red;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;Height&lt;/span&gt;&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;="340"&lt;/span&gt; &lt;span style="color:Red;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;Width&lt;/span&gt;&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;="300"&lt;/span&gt;
        &lt;span style="color:Red;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;xmlns:local&lt;/span&gt;&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;="clr-namespace:ToDoListTest.ViewModels"&lt;/span&gt;
        &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;&amp;gt;&lt;/span&gt;
    &amp;lt;Window.DataContext&amp;gt;
        &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:Maroon;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;local:AddItemsViewModel&lt;/span&gt; &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;/&amp;gt;&lt;/span&gt;
    &amp;lt;/Window.DataContext&amp;gt;
    &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:Maroon;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;Grid&lt;/span&gt;&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;&amp;gt;&lt;/span&gt;
        &amp;lt;Grid.ColumnDefinitions&amp;gt;
            &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:Maroon;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;ColumnDefinition&lt;/span&gt; &lt;span style="color:Red;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;Width&lt;/span&gt;&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;="79*"&lt;/span&gt; &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;/&amp;gt;&lt;/span&gt;
            &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:Maroon;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;ColumnDefinition&lt;/span&gt; &lt;span style="color:Red;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;Width&lt;/span&gt;&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;="199*"&lt;/span&gt; &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;/&amp;gt;&lt;/span&gt;
        &amp;lt;/Grid.ColumnDefinitions&amp;gt;
        &amp;lt;Grid.RowDefinitions&amp;gt;
            &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:Maroon;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;RowDefinition&lt;/span&gt; &lt;span style="color:Red;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;Height&lt;/span&gt;&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;="Auto"&lt;/span&gt; &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;/&amp;gt;&lt;/span&gt;
            &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:Maroon;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;RowDefinition&lt;/span&gt; &lt;span style="color:Red;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;Height&lt;/span&gt;&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;="Auto"&lt;/span&gt; &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;/&amp;gt;&lt;/span&gt;
            &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:Maroon;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;RowDefinition&lt;/span&gt; &lt;span style="color:Red;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;Height&lt;/span&gt;&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;="Auto"&lt;/span&gt; &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;/&amp;gt;&lt;/span&gt;
            &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:Maroon;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;RowDefinition&lt;/span&gt; &lt;span style="color:Red;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;Height&lt;/span&gt;&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;="202*"&lt;/span&gt; &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;/&amp;gt;&lt;/span&gt;
        &amp;lt;/Grid.RowDefinitions&amp;gt;
        &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:Maroon;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;Label&lt;/span&gt; &lt;span style="color:Red;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;Content&lt;/span&gt;&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;="Name"&lt;/span&gt; &lt;span style="color:Red;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;Height&lt;/span&gt;&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;="28"&lt;/span&gt; &lt;span style="color:Red;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;HorizontalAlignment&lt;/span&gt;&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;="Left"&lt;/span&gt; &lt;span style="color:Red;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;Margin&lt;/span&gt;&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;="7,4,0,0"&lt;/span&gt; &lt;span style="color:Red;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;Name&lt;/span&gt;&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;="label1"&lt;/span&gt; &lt;span style="color:Red;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;VerticalAlignment&lt;/span&gt;&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;="Top"&lt;/span&gt; &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;/&amp;gt;&lt;/span&gt;
        &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:Maroon;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;Label&lt;/span&gt; &lt;span style="color:Red;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;Content&lt;/span&gt;&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;="Description"&lt;/span&gt; &lt;span style="color:Red;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;Height&lt;/span&gt;&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;="28"&lt;/span&gt; &lt;span style="color:Red;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;HorizontalAlignment&lt;/span&gt;&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;="Left"&lt;/span&gt; &lt;span style="color:Red;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;Margin&lt;/span&gt;&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;="7,0,0,0"&lt;/span&gt; &lt;span style="color:Red;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;Name&lt;/span&gt;&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;="label2"&lt;/span&gt; &lt;span style="color:Red;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;VerticalAlignment&lt;/span&gt;&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;="Top"&lt;/span&gt;&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;&lt;/span&gt; Grid.Row="1" /&amp;gt;
        &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:Maroon;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;Label&lt;/span&gt; &lt;span style="color:Red;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;Content&lt;/span&gt;&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;="Date To Act"&lt;/span&gt; &lt;span style="color:Red;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;Height&lt;/span&gt;&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;="28"&lt;/span&gt; &lt;span style="color:Red;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;HorizontalAlignment&lt;/span&gt;&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;="Left"&lt;/span&gt; &lt;span style="color:Red;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;Margin&lt;/span&gt;&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;="7,0,0,138"&lt;/span&gt; &lt;span style="color:Red;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;Name&lt;/span&gt;&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;="label3"&lt;/span&gt; &lt;span style="color:Red;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;VerticalAlignment&lt;/span&gt;&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;="Bottom"&lt;/span&gt;&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;&lt;/span&gt; Grid.Row="2" /&amp;gt;
        &amp;lt;TextBox Grid.Column="1" Text="{Binding Path=ActiveItem.Name, Mode=TwoWay}" Height="23" HorizontalAlignment="Left" Margin="6,9,0,0" VerticalAlignment="Top" Width="181" /&amp;gt;
        &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:Maroon;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;TextBox&lt;/span&gt; &lt;span style="color:Red;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;Height&lt;/span&gt;&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;="56"&lt;/span&gt; &lt;span style="color:Red;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;Text&lt;/span&gt;&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;="{Binding Path=ActiveItem.Description, Mode=TwoWay}"&lt;/span&gt; &lt;span style="color:Red;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;HorizontalAlignment&lt;/span&gt;&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;="Left"&lt;/span&gt; &lt;span style="color:Red;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;Margin&lt;/span&gt;&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;="6,5,0,0"&lt;/span&gt; &lt;span style="color:Red;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;VerticalAlignment&lt;/span&gt;&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;="Top"&lt;/span&gt; &lt;span style="color:Red;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;Width&lt;/span&gt;&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;="180"&lt;/span&gt;&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;&lt;/span&gt; Grid.Column="1" Grid.Row="1" TextWrapping="Wrap" /&amp;gt;
        &amp;lt;Calendar Grid.Column="1" SelectedDate="{Binding Path=ActiveItem.DateToAct, Mode=TwoWay}" Grid.Row="2" Height="170" HorizontalAlignment="Left" Margin="7,0,0,0" VerticalAlignment="Top" Width="180" Grid.RowSpan="2" /&amp;gt;
        &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:Maroon;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;Button&lt;/span&gt; &lt;span style="color:Red;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;Content&lt;/span&gt;&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;="Save"&lt;/span&gt; &lt;span style="color:Red;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;Command&lt;/span&gt;&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;="{Binding SaveItem}"&lt;/span&gt;&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;&lt;/span&gt; Grid.Column="1" Grid.Row="3" Height="23" HorizontalAlignment="Left" Margin="116,10,0,0" Name="button1" VerticalAlignment="Top" Width="75" /&amp;gt;
    &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:Maroon;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;Grid&lt;/span&gt;&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;&amp;gt;&lt;/span&gt;
&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:Maroon;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;Window&lt;/span&gt;&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;&amp;gt;&lt;/span&gt;&lt;/span&gt;&lt;/pre&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/table&gt;&lt;br&gt;&lt;/div&gt;&lt;div&gt;AddItemsViewModel&lt;/div&gt;&lt;div&gt;&lt;table border="0" cellpadding="0" cellspacing="0" width="100%" style="background-color:#f2f2f2;border:solid 1px #e5e5e5;"&gt;&lt;tr style="vertical-align:top;line-height:normal;"&gt;&lt;td style="width:40px;text-align:right;"&gt;&lt;pre style="font-family:courier new;font-size:11px;color:gray;margin:0px;padding:2px;border-right:solid 1px #e7e7e7;"&gt;1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
 &lt;/pre&gt;&lt;/td&gt;&lt;td&gt;&lt;pre style="margin:0px;padding:2px;padding-left:8px;"&gt;&lt;span style="color:Black;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;using&lt;/span&gt; System;
&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;using&lt;/span&gt; System.Collections.Generic;
&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;using&lt;/span&gt; System.Linq;
&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;using&lt;/span&gt; System.Text;
&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;using&lt;/span&gt; ToDoListTest.Services;
&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;using&lt;/span&gt; Domain;
&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;using&lt;/span&gt; ToDoListTest.Infrastructure;
&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;using&lt;/span&gt; System.Windows.Input;

&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;namespace&lt;/span&gt; ToDoListTest.ViewModels {
    &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;public&lt;/span&gt; &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;class&lt;/span&gt; AddItemsViewModel : ObservableObject {

        &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;#region&lt;/span&gt; Declarations
        &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;readonly&lt;/span&gt; IDialogService _dialog;
        &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;#endregion&lt;/span&gt;

        &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;#region&lt;/span&gt; Constructors
        &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;public&lt;/span&gt; AddItemsViewModel() {
            &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;this&lt;/span&gt;.ActiveItem &lt;span style="color:Red;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;=&lt;/span&gt; &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;new&lt;/span&gt; Item();
        }

        &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;public&lt;/span&gt; AddItemsViewModel(IDialogService dialog, Item activeItem) {
            &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;this&lt;/span&gt;._dialog &lt;span style="color:Red;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;=&lt;/span&gt; dialog;
            ActiveItem &lt;span style="color:Red;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;=&lt;/span&gt; activeItem;
        }
        &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;#endregion&lt;/span&gt;

        &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;#region&lt;/span&gt; Commands
        &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;public&lt;/span&gt; ICommand SaveItem {
            get { &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;return&lt;/span&gt; &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;new&lt;/span&gt; RelayCommand(SaveItemExecute); }
        }
        &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;#endregion&lt;/span&gt;

        &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;#region&lt;/span&gt; Properties
        Item _activeItem;
        &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;public&lt;/span&gt; Item ActiveItem {
            get { &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;return&lt;/span&gt; _activeItem; }
            set {
                _activeItem &lt;span style="color:Red;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;=&lt;/span&gt; value;
                RaisePropertyChanged(&lt;span style="color:#666666;background-color:#e4e4e4;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;"ActiveItem"&lt;/span&gt;);
            }
        }
        &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;#endregion&lt;/span&gt;

        &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;#region&lt;/span&gt; Methods
        &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;void&lt;/span&gt; SaveItemExecute() {
            &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;try&lt;/span&gt; {
                &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;using&lt;/span&gt; (var toDoListDB &lt;span style="color:Red;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;=&lt;/span&gt; &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;new&lt;/span&gt; ToDoDBEntities()) {
                    var i &lt;span style="color:Red;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;=&lt;/span&gt; &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;new&lt;/span&gt; Item {
                        DateCreated &lt;span style="color:Red;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;=&lt;/span&gt; DateTime.Now,
                        DateToAct &lt;span style="color:Red;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;=&lt;/span&gt; &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;this&lt;/span&gt;.ActiveItem.DateToAct,
                        Description &lt;span style="color:Red;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;=&lt;/span&gt; &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;this&lt;/span&gt;.ActiveItem.Description,
                        ID &lt;span style="color:Red;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;=&lt;/span&gt; Guid.NewGuid(),
                        Name &lt;span style="color:Red;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;=&lt;/span&gt; &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;this&lt;/span&gt;.ActiveItem.Name
                    };
                    toDoListDB.Items.AddObject(i);
                    toDoListDB.SaveChanges();
                    var addItems &lt;span style="color:Red;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;=&lt;/span&gt; &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;new&lt;/span&gt; AddItems();
                    addItems.Close();
                }
            } &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;catch&lt;/span&gt; (Exception ex) {

                &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;this&lt;/span&gt;._dialog.ShowException(ex.Message);
            }
        }
        &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;#endregion&lt;/span&gt;

    }
}&lt;/span&gt;&lt;/pre&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/table&gt;&lt;br&gt;&lt;/div&gt;&lt;div&gt;MainWindowViewModel&lt;/div&gt;&lt;div&gt;&lt;table border="0" cellpadding="0" cellspacing="0" width="100%" style="background-color:#f2f2f2;border:solid 1px #e5e5e5;"&gt;&lt;tr style="vertical-align:top;line-height:normal;"&gt;&lt;td style="width:40px;text-align:right;"&gt;&lt;pre style="font-family:courier new;font-size:11px;color:gray;margin:0px;padding:2px;border-right:solid 1px #e7e7e7;"&gt;1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
 &lt;/pre&gt;&lt;/td&gt;&lt;td&gt;&lt;pre style="margin:0px;padding:2px;padding-left:8px;"&gt;&lt;span style="color:Black;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;using&lt;/span&gt; System;
&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;using&lt;/span&gt; System.Collections.Generic;
&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;using&lt;/span&gt; System.Linq;
&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;using&lt;/span&gt; System.Text;
&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;using&lt;/span&gt; System.Windows.Input;
&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;using&lt;/span&gt; ToDoListTest.Infrastructure;
&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;using&lt;/span&gt; Domain;
&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;using&lt;/span&gt; System.Collections.ObjectModel;
&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;using&lt;/span&gt; ToDoListTest.Services;
&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;using&lt;/span&gt; Domain.Collections;
&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;using&lt;/span&gt; System.Windows.Data;

&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;namespace&lt;/span&gt; ToDoListTest.ViewModels {
    &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;public&lt;/span&gt; &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;class&lt;/span&gt; MainWindowViewModel : ObservableObject {

        &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;#region&lt;/span&gt; Declarations
        &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;readonly&lt;/span&gt; IDialogService _dialog;
        &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;#endregion&lt;/span&gt;

        &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;#region&lt;/span&gt; Properties
        &lt;span style="color:Green;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;//ObservableCollection&amp;lt;Item&amp;gt; _itemResults;&lt;/span&gt;
        &lt;span style="color:Green;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;//public ObservableCollection&amp;lt;Item&amp;gt; ItemResults {&lt;/span&gt;
        &lt;span style="color:Green;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;//    get { return _itemResults; }&lt;/span&gt;
        &lt;span style="color:Green;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;//    set {&lt;/span&gt;
        &lt;span style="color:Green;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;//        _itemResults = value;&lt;/span&gt;
        &lt;span style="color:Green;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;//        RaisePropertyChanged("ItemResults");&lt;/span&gt;
        &lt;span style="color:Green;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;//    }&lt;/span&gt;
        &lt;span style="color:Green;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;//}&lt;/span&gt;

        &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;public&lt;/span&gt; List&amp;lt;Item&amp;gt; ItemResults { get; set; }

        Item _activeItem;
        &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;public&lt;/span&gt; Item ActiveItem {
            get { &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;return&lt;/span&gt; _activeItem; }
            set {
                _activeItem &lt;span style="color:Red;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;=&lt;/span&gt; value;
                RaisePropertyChanged(&lt;span style="color:#666666;background-color:#e4e4e4;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;"ActiveItem"&lt;/span&gt;);
            }
        }
        &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;#endregion&lt;/span&gt;

        &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;#region&lt;/span&gt; Constructors

        &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;public&lt;/span&gt; MainWindowViewModel() : &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;this&lt;/span&gt;(&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;new&lt;/span&gt; ModalDialogService()) { }

        &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;public&lt;/span&gt; MainWindowViewModel(IDialogService dialog) {
            &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;this&lt;/span&gt;._dialog &lt;span style="color:Red;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;=&lt;/span&gt; dialog;
            LoadItemResults();
        }
        &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;#endregion&lt;/span&gt;

        &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;#region&lt;/span&gt; Commands
        &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;public&lt;/span&gt; ICommand AddNewItem {
            get { &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;return&lt;/span&gt; &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;new&lt;/span&gt; RelayCommand(AddNewItemExecute); }
        }
        &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;#endregion&lt;/span&gt;

        &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;#region&lt;/span&gt; Methods
        &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;void&lt;/span&gt; AddNewItemExecute() {
            &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;if&lt;/span&gt; (&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;this&lt;/span&gt;.ActiveItem == &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;null&lt;/span&gt;) {
                &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;this&lt;/span&gt;.ActiveItem &lt;span style="color:Red;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;=&lt;/span&gt; &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;new&lt;/span&gt; Item();
            }

            AddItemsViewModel addItemsViewModel &lt;span style="color:Red;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;=&lt;/span&gt; &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;new&lt;/span&gt; AddItemsViewModel(&lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;this&lt;/span&gt;._dialog, &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;this&lt;/span&gt;.ActiveItem);
            var addItems &lt;span style="color:Red;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;=&lt;/span&gt; &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;new&lt;/span&gt; AddItems();
            addItems.Show();
        }

        &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;void&lt;/span&gt; LoadItemResults() {
            ItemsCollection itemsCollection;
            &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;try&lt;/span&gt; {
                
                &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;using&lt;/span&gt; (var toDoListDB &lt;span style="color:Red;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;=&lt;/span&gt; &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;new&lt;/span&gt; ToDoDBEntities()) {
                    &lt;span style="color:Green;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;//itemsCollection = new ItemsCollection(toDoListDB.Items.ToList());&lt;/span&gt;
                    &lt;span style="color:Green;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;//var itemCVS = new CollectionViewSource();&lt;/span&gt;
                    &lt;span style="color:Green;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;//var itemSource = (CollectionViewSource)this.Resources("itemSource");&lt;/span&gt;
                    &lt;span style="color:Green;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;//itemCVS.Source = toDoListDB.Items.ToList();&lt;/span&gt;
                    &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;this&lt;/span&gt;.ItemResults &lt;span style="color:Red;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;=&lt;/span&gt; toDoListDB.Items.ToList();   
                }
                &lt;span style="color:Green;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;//ItemRepository itemRepos = new ItemRepository(new EFRepository&amp;lt;Item&amp;gt;(), new EFUnitOfWork());&lt;/span&gt;
                &lt;span style="color:Green;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;//this.ItemResults = itemRepos.All();&lt;/span&gt;
            } &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;catch&lt;/span&gt; (Exception ex) {
                &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;this&lt;/span&gt;._dialog.ShowException(ex.Message);
            }
        }
        &lt;span style="color:Blue;background-color:Transparent;font-family:Courier New;font-size:11px;font-weight:normal;"&gt;#endregion&lt;/span&gt;
    }
}&lt;/span&gt;&lt;/pre&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/table&gt;&lt;br&gt;&lt;/div&gt;&lt;div&gt;&lt;br&gt;&lt;/div&gt;&lt;div&gt;&lt;font class="Apple-style-span" size="2" face="Arial"&gt;Το addNew window ανοίγει απο το &lt;i&gt;Command&amp;nbsp;&lt;/i&gt;&lt;span class="Apple-style-span" style="white-space:pre;"&gt;&lt;b&gt;AddNewItem &lt;/b&gt;που βρίσκεται στο &lt;/span&gt;&lt;b&gt;MainWindowViewModel&amp;nbsp;&lt;/b&gt;στην γραμμή 53&lt;/font&gt;&lt;/div&gt;</description></item><item><title>Απ: Interact to mainWindow ListView</title><link>https://www.dotnetzone.gr:443/cs/forums/thread/62797.aspx</link><pubDate>Mon, 31 Jan 2011 01:17:16 GMT</pubDate><guid isPermaLink="false">2622095e-976c-431a-859e-16783ec7ecd7:62797</guid><dc:creator>KelMan</dc:creator><slash:comments>0</slash:comments><comments>https://www.dotnetzone.gr:443/cs/forums/thread/62797.aspx</comments><wfw:commentRss>https://www.dotnetzone.gr:443/cs/forums/commentrss.aspx?SectionID=80&amp;PostID=62797</wfw:commentRss><description>&lt;P&gt;To Prism δεν είναι εύκολο και σίγουρα δεν πρέπει να πάρεις την απόφαση να το χρησιμοποιήσεις επειδή απλά το ανέφερα στην απάντησή μου. Θα είναι σαν να χρησιμοποιείς ένα τριαξονικό για να πας μέχρι το περίπτερο. Πριν βιαστείς με το Prism καλύτερα να πεις πώς έχεις υλοποιήσει το να βγαίνει η φόρμα του addNew μέσα από την Main.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description></item><item><title>Απ: Interact to mainWindow ListView</title><link>https://www.dotnetzone.gr:443/cs/forums/thread/62796.aspx</link><pubDate>Mon, 31 Jan 2011 00:57:03 GMT</pubDate><guid isPermaLink="false">2622095e-976c-431a-859e-16783ec7ecd7:62796</guid><dc:creator>StrouMfios</dc:creator><slash:comments>0</slash:comments><comments>https://www.dotnetzone.gr:443/cs/forums/thread/62796.aspx</comments><wfw:commentRss>https://www.dotnetzone.gr:443/cs/forums/commentrss.aspx?SectionID=80&amp;PostID=62796</wfw:commentRss><description>Ακόμα δεν έχω χρησιμοποιήσει κάποιο απο αυτά που μου ανέφερες.&lt;div&gt;Δέν ήξερα με ποιόν τρόπο μπορεί να γίνει κάτι τέτοιο, αλλα τώρα θα ψάξω για το prism ώστε να το εφαρμόσω στο app.&lt;/div&gt;&lt;div&gt;&lt;br&gt;&lt;/div&gt;&lt;div&gt;Το INotifyPropertyChanged παίζει κάοιο ρόλο σε αυτό που προσπαθώ να κάνω?&lt;/div&gt;</description></item><item><title>Απ: Interact to mainWindow ListView</title><link>https://www.dotnetzone.gr:443/cs/forums/thread/62795.aspx</link><pubDate>Mon, 31 Jan 2011 00:50:26 GMT</pubDate><guid isPermaLink="false">2622095e-976c-431a-859e-16783ec7ecd7:62795</guid><dc:creator>KelMan</dc:creator><slash:comments>0</slash:comments><comments>https://www.dotnetzone.gr:443/cs/forums/thread/62795.aspx</comments><wfw:commentRss>https://www.dotnetzone.gr:443/cs/forums/commentrss.aspx?SectionID=80&amp;PostID=62795</wfw:commentRss><description>&lt;P&gt;Τυπικά το mainWindow και το&amp;nbsp;addNewItemWindow θα πρέπει να είναι binded το καθένα στο δικό του ViewModel. Όπερ σημαίνει ότι το ListView σε κάθε ένα View θα πρέπει να είναι binded στο αντίστοιχο collection property του ViewModel. Άρα το μόνο που χρειάζεται είναι να ενημερώσεις το collection του main ViewModel για τα νέα items που υπάρχουν στο collection του addNewItem ViewModel. &lt;/P&gt;
&lt;P&gt;Τώρα, το πώς θα το κάνεις αυτό εξαρτάται από τον τρόπο που έχεις υλοποιήσει το switching ανάμεσα στα Views. Στις απλές περιπτώσεις υπάρχει η τεχνική των sub-ViewModels (υπάρχει ένα κεντρικό το οποίο συντονίζει όλα υπόλοιπα), μπορεί να έχεις υλοποιήσει το Locator pattern ή να έχεις χρησιμοποιήσει κάποιο framework (πχ Ocean, Prism, κλπ). Εσύ πώς το έχεις κάνει;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description></item><item><title>Απ: Interact to mainWindow ListView</title><link>https://www.dotnetzone.gr:443/cs/forums/thread/62793.aspx</link><pubDate>Sun, 30 Jan 2011 22:10:22 GMT</pubDate><guid isPermaLink="false">2622095e-976c-431a-859e-16783ec7ecd7:62793</guid><dc:creator>dimos.homatas</dc:creator><slash:comments>0</slash:comments><comments>https://www.dotnetzone.gr:443/cs/forums/thread/62793.aspx</comments><wfw:commentRss>https://www.dotnetzone.gr:443/cs/forums/commentrss.aspx?SectionID=80&amp;PostID=62793</wfw:commentRss><description>Δεν ξέρω αν έχει καμία διαφορά με τα winforms, αλλά αν θες να έχεις πρόσβαση σε control από οπουδήποτε, πάνε στο modifier του και από private κάντο internal.&lt;div&gt;&lt;br&gt;&lt;/div&gt;&lt;div&gt;Βέβαια ο πιο ορθόδοξος τρόπος είναι η δεύτερη φόρμα να έχει κάποιο property που να επιστρέφει το item που θέλεις και να το διαχειρίζεται μετά η μαμά φόρμα πχ κάτι αντίστοιχο σαν το DialogResult.&lt;/div&gt;</description></item><item><title>Interact to mainWindow ListView</title><link>https://www.dotnetzone.gr:443/cs/forums/thread/62792.aspx</link><pubDate>Sun, 30 Jan 2011 21:47:46 GMT</pubDate><guid isPermaLink="false">2622095e-976c-431a-859e-16783ec7ecd7:62792</guid><dc:creator>StrouMfios</dc:creator><slash:comments>0</slash:comments><comments>https://www.dotnetzone.gr:443/cs/forums/thread/62792.aspx</comments><wfw:commentRss>https://www.dotnetzone.gr:443/cs/forums/commentrss.aspx?SectionID=80&amp;PostID=62792</wfw:commentRss><description>Καλησπέρα σε όλους,&lt;div&gt;&lt;br&gt;&lt;/div&gt;&lt;div&gt;προσπαθώ να φτιάξω ένα μικρό πρόγραμμα σε wpf για λόγους πρακτικής και μόνο.&lt;/div&gt;&lt;div&gt;Αυτό που θέλω να κάνω είναι μια ToDoList η οποία θα έχει στο mainWindow όλα τα items σε ένα ListView.&amp;nbsp;&lt;/div&gt;&lt;div&gt;Στο mainWIndow &amp;nbsp;θα έχει και ένα button το οποίο θα ανοίγει ένα window(&lt;i&gt;addNewItemWindow&lt;/i&gt;) στο οποίο θα γίνεται εισαγωγή νέου item.&lt;/div&gt;&lt;div&gt;Μέχρι στιγμής η υλοποίηση έχει γίνει με το MVVM pattern και Entity Framework.&amp;nbsp;&lt;/div&gt;&lt;div&gt;&lt;br&gt;&lt;/div&gt;&lt;div&gt;&lt;b&gt;Ερώτηση&lt;/b&gt;&lt;/div&gt;&lt;div&gt;Πως μπορώ από το addNewItemWindow με το πάτημα του κουμπιού save να εμφανίζεται το item στο ListView του mainWindow?&amp;nbsp;&lt;/div&gt;&lt;div&gt;Γενικότερα ψάχνω έναν τρόπο με τον οποίο να μπορώ να ανανεώνω την ListView από οποιοδήποτε σημείο του application.&lt;/div&gt;&lt;div&gt;&lt;br&gt;&lt;/div&gt;&lt;div&gt;Ευχαριστώ&lt;/div&gt;</description></item></channel></rss>