<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
		>
<channel>
	<title>Comments on: How to close a View from a ViewModel ?</title>
	<atom:link href="http://www.japf.fr/2009/09/how-to-close-a-view-from-a-viewmodel/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.japf.fr/2009/09/how-to-close-a-view-from-a-viewmodel/</link>
	<description>Jeremy Alles Presentation Foundation: WPF, Silverlight, Windows Phone 7, Windows 8</description>
	<lastBuildDate>Fri, 13 Jan 2012 15:59:10 +0000</lastBuildDate>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
	<item>
		<title>By: Sam</title>
		<link>http://www.japf.fr/2009/09/how-to-close-a-view-from-a-viewmodel/comment-page-1/#comment-3153</link>
		<dc:creator>Sam</dc:creator>
		<pubDate>Thu, 25 Aug 2011 01:23:52 +0000</pubDate>
		<guid isPermaLink="false">http://www.japf.fr/?p=252#comment-3153</guid>
		<description>Hi,

I have a very basic question. (I am new to WPF.)

In your solution 2, how could you raise event &quot;RequestClose&quot; from ViewModel?  I use RequestClose.Invoke(this, new EventArgs()) but the view.close doesn&#039;t seem to be triggered.

Thanks a lot!</description>
		<content:encoded><![CDATA[<p>Hi,</p>
<p>I have a very basic question. (I am new to WPF.)</p>
<p>In your solution 2, how could you raise event &#8220;RequestClose&#8221; from ViewModel?  I use RequestClose.Invoke(this, new EventArgs()) but the view.close doesn&#8217;t seem to be triggered.</p>
<p>Thanks a lot!</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Nikolai</title>
		<link>http://www.japf.fr/2009/09/how-to-close-a-view-from-a-viewmodel/comment-page-1/#comment-3094</link>
		<dc:creator>Nikolai</dc:creator>
		<pubDate>Fri, 17 Jun 2011 06:54:40 +0000</pubDate>
		<guid isPermaLink="false">http://www.japf.fr/?p=252#comment-3094</guid>
		<description>I like this approach, as WPF+MVVM combo matures we will see evolved implementations. But it makes sense to keep things simple in the interim. This is a very simple and reliable solution.</description>
		<content:encoded><![CDATA[<p>I like this approach, as WPF+MVVM combo matures we will see evolved implementations. But it makes sense to keep things simple in the interim. This is a very simple and reliable solution.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Jeremy</title>
		<link>http://www.japf.fr/2009/09/how-to-close-a-view-from-a-viewmodel/comment-page-1/#comment-1168</link>
		<dc:creator>Jeremy</dc:creator>
		<pubDate>Mon, 01 Mar 2010 22:10:39 +0000</pubDate>
		<guid isPermaLink="false">http://www.japf.fr/?p=252#comment-1168</guid>
		<description>Rob, 

As I said at the end of the post, this is a very basic implementation. If you need more sophisticated features you would have a dedicated service to manage lifetime of Window. You can take a look at the Calcium framework.</description>
		<content:encoded><![CDATA[<p>Rob, </p>
<p>As I said at the end of the post, this is a very basic implementation. If you need more sophisticated features you would have a dedicated service to manage lifetime of Window. You can take a look at the Calcium framework.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Rob</title>
		<link>http://www.japf.fr/2009/09/how-to-close-a-view-from-a-viewmodel/comment-page-1/#comment-1053</link>
		<dc:creator>Rob</dc:creator>
		<pubDate>Tue, 02 Feb 2010 22:43:45 +0000</pubDate>
		<guid isPermaLink="false">http://www.japf.fr/?p=252#comment-1053</guid>
		<description>This doesnt really help though when the VM is behind a user control somewhere down the visual tree, which is more likely. How would you get the event fired from this VM to bubble up to the window that contains the usercontrol which has this Vm as its datacontext?</description>
		<content:encoded><![CDATA[<p>This doesnt really help though when the VM is behind a user control somewhere down the visual tree, which is more likely. How would you get the event fired from this VM to bubble up to the window that contains the usercontrol which has this Vm as its datacontext?</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Jeremy</title>
		<link>http://www.japf.fr/2009/09/how-to-close-a-view-from-a-viewmodel/comment-page-1/#comment-1031</link>
		<dc:creator>Jeremy</dc:creator>
		<pubDate>Wed, 27 Jan 2010 11:59:26 +0000</pubDate>
		<guid isPermaLink="false">http://www.japf.fr/?p=252#comment-1031</guid>
		<description>I think you could use a Behavior that execute a command whenever a Window is closing. In the command target you could use some kind of &quot;DialogService&quot; to find a service which would open the dialogbox for you :-)</description>
		<content:encoded><![CDATA[<p>I think you could use a Behavior that execute a command whenever a Window is closing. In the command target you could use some kind of &#8220;DialogService&#8221; to find a service which would open the dialogbox for you <img src='http://www.japf.fr/wp-includes/images/smilies/icon_smile.gif' alt=':-)' class='wp-smiley' /> </p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Daniel Skinner</title>
		<link>http://www.japf.fr/2009/09/how-to-close-a-view-from-a-viewmodel/comment-page-1/#comment-1029</link>
		<dc:creator>Daniel Skinner</dc:creator>
		<pubDate>Wed, 27 Jan 2010 10:58:05 +0000</pubDate>
		<guid isPermaLink="false">http://www.japf.fr/?p=252#comment-1029</guid>
		<description>Regarding closing the window with the X: What if we need to show a save changes dialog for example?</description>
		<content:encoded><![CDATA[<p>Regarding closing the window with the X: What if we need to show a save changes dialog for example?</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: JAPF &#187; Blog Archive &#187; Review of 2009 blog posts</title>
		<link>http://www.japf.fr/2009/09/how-to-close-a-view-from-a-viewmodel/comment-page-1/#comment-969</link>
		<dc:creator>JAPF &#187; Blog Archive &#187; Review of 2009 blog posts</dc:creator>
		<pubDate>Wed, 06 Jan 2010 19:02:34 +0000</pubDate>
		<guid isPermaLink="false">http://www.japf.fr/?p=252#comment-969</guid>
		<description>[...] How to close a View from a ViewModel ? [...]</description>
		<content:encoded><![CDATA[<p>[...] How to close a View from a ViewModel ? [...]</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Jeremy</title>
		<link>http://www.japf.fr/2009/09/how-to-close-a-view-from-a-viewmodel/comment-page-1/#comment-491</link>
		<dc:creator>Jeremy</dc:creator>
		<pubDate>Tue, 20 Oct 2009 08:09:04 +0000</pubDate>
		<guid isPermaLink="false">http://www.japf.fr/?p=252#comment-491</guid>
		<description>Well in this case the closing procedure is handled by WPF itself right ? What do you want to do in particular ?</description>
		<content:encoded><![CDATA[<p>Well in this case the closing procedure is handled by WPF itself right ? What do you want to do in particular ?</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: arconaut</title>
		<link>http://www.japf.fr/2009/09/how-to-close-a-view-from-a-viewmodel/comment-page-1/#comment-486</link>
		<dc:creator>arconaut</dc:creator>
		<pubDate>Mon, 19 Oct 2009 16:19:24 +0000</pubDate>
		<guid isPermaLink="false">http://www.japf.fr/?p=252#comment-486</guid>
		<description>Thanks for this useful post!
But how would you handle closing of a window when user clicks the default window&#039;s Close button? (&quot;Red X&quot;)</description>
		<content:encoded><![CDATA[<p>Thanks for this useful post!<br />
But how would you handle closing of a window when user clicks the default window&#8217;s Close button? (&#8220;Red X&#8221;)</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Bob Bartholomay</title>
		<link>http://www.japf.fr/2009/09/how-to-close-a-view-from-a-viewmodel/comment-page-1/#comment-428</link>
		<dc:creator>Bob Bartholomay</dc:creator>
		<pubDate>Tue, 29 Sep 2009 20:29:05 +0000</pubDate>
		<guid isPermaLink="false">http://www.japf.fr/?p=252#comment-428</guid>
		<description>I blogged about a similar (same?) forum post a few days ago and my research revealed few alternatives that may be of interest see: http://blog.flexforcefive.com/?p=206</description>
		<content:encoded><![CDATA[<p>I blogged about a similar (same?) forum post a few days ago and my research revealed few alternatives that may be of interest see: <a href="http://blog.flexforcefive.com/?p=206" rel="nofollow">http://blog.flexforcefive.com/?p=206</a></p>
]]></content:encoded>
	</item>
</channel>
</rss>

