<?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: Never ever close me &#8211; how to disable close button in WPF</title>
	<atom:link href="http://khason.net/blog/never-ever-close-me-how-to-disable-close-button-in-wpf/feed/" rel="self" type="application/rss+xml" />
	<link>http://khason.net/blog/never-ever-close-me-how-to-disable-close-button-in-wpf/</link>
	<description>Take care of the sense, and the sounds will take care of themselves.</description>
	<lastBuildDate>Tue, 16 Mar 2010 01:26:13 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.9.2</generator>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
		<item>
		<title>By: YOU UGLY MAMA</title>
		<link>http://khason.net/blog/never-ever-close-me-how-to-disable-close-button-in-wpf/comment-page-1/#comment-3301</link>
		<dc:creator>YOU UGLY MAMA</dc:creator>
		<pubDate>Tue, 15 Sep 2009 19:45:34 +0000</pubDate>
		<guid isPermaLink="false">http://khason.net/blog/never-ever-close-me-how-to-disable-close-button-in-wpf/#comment-3301</guid>
		<description>HEY YOU DUMB AHOLE TAMIT THE HOMO HOW ABOUT POSTING A WPF PROJECT WITH SOURCE INSTEAD OF JUST COPYING AND PASTING</description>
		<content:encoded><![CDATA[<p>HEY YOU DUMB AHOLE TAMIT THE HOMO HOW ABOUT POSTING A WPF PROJECT WITH SOURCE INSTEAD OF JUST COPYING AND PASTING</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Nick</title>
		<link>http://khason.net/blog/never-ever-close-me-how-to-disable-close-button-in-wpf/comment-page-1/#comment-3141</link>
		<dc:creator>Nick</dc:creator>
		<pubDate>Wed, 15 Jul 2009 16:09:57 +0000</pubDate>
		<guid isPermaLink="false">http://khason.net/blog/never-ever-close-me-how-to-disable-close-button-in-wpf/#comment-3141</guid>
		<description>Can you please change the source code color........it&#039;s really not readable. I mean light blue and light green they are not clearly visible</description>
		<content:encoded><![CDATA[<p>Can you please change the source code color&#8230;&#8230;..it&#8217;s really not readable. I mean light blue and light green they are not clearly visible</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Gagan Rajpal</title>
		<link>http://khason.net/blog/never-ever-close-me-how-to-disable-close-button-in-wpf/comment-page-1/#comment-797</link>
		<dc:creator>Gagan Rajpal</dc:creator>
		<pubDate>Thu, 01 Jan 2009 08:23:47 +0000</pubDate>
		<guid isPermaLink="false">http://khason.net/blog/never-ever-close-me-how-to-disable-close-button-in-wpf/#comment-797</guid>
		<description>&lt;p&gt;There is a much simpler but WPF solution too:&lt;/p&gt;
&lt;p&gt;Just subscribe to the Windows Closing Event and in the handler set e.Cancel = true&lt;/p&gt;
&lt;p&gt;eg:&lt;/p&gt;
&lt;p&gt; &#160; &#160;public partial class Window1 : Window&lt;/p&gt;
&lt;p&gt; &#160; &#160;{&lt;/p&gt;
&lt;p&gt; &#160; &#160; &#160; &#160;public Window1()&lt;/p&gt;
&lt;p&gt; &#160; &#160; &#160; &#160;{&lt;/p&gt;
&lt;p&gt; &#160; &#160; &#160; &#160; &#160; &#160;InitializeComponent();&lt;/p&gt;
&lt;p&gt; &#160; &#160; &#160; &#160; &#160; &#160;this.Closing += new &#160; &#160; &#160; System.ComponentModel.CancelEventHandler(Window1_Closing);&lt;/p&gt;
&lt;p&gt; &#160; &#160; &#160; &#160;}&lt;/p&gt;
&lt;p&gt; &#160; &#160; &#160; &#160;void Window1_Closing(object sender, System.ComponentModel.CancelEventArgs e)&lt;/p&gt;
&lt;p&gt; &#160; &#160; &#160; &#160;{&lt;/p&gt;
&lt;p&gt; &#160; &#160; &#160; &#160; &#160; &#160;e.Cancel = true;&lt;/p&gt;
&lt;p&gt; &#160; &#160; &#160; &#160;}&lt;/p&gt;
&lt;p&gt; &#160; &#160;}&lt;/p&gt;
</description>
		<content:encoded><![CDATA[<p>There is a much simpler but WPF solution too:</p>
<p>Just subscribe to the Windows Closing Event and in the handler set e.Cancel = true</p>
<p>eg:</p>
<p> &nbsp; &nbsp;public partial class Window1 : Window</p>
<p> &nbsp; &nbsp;{</p>
<p> &nbsp; &nbsp; &nbsp; &nbsp;public Window1()</p>
<p> &nbsp; &nbsp; &nbsp; &nbsp;{</p>
<p> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;InitializeComponent();</p>
<p> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;this.Closing += new &nbsp; &nbsp; &nbsp; System.ComponentModel.CancelEventHandler(Window1_Closing);</p>
<p> &nbsp; &nbsp; &nbsp; &nbsp;}</p>
<p> &nbsp; &nbsp; &nbsp; &nbsp;void Window1_Closing(object sender, System.ComponentModel.CancelEventArgs e)</p>
<p> &nbsp; &nbsp; &nbsp; &nbsp;{</p>
<p> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;e.Cancel = true;</p>
<p> &nbsp; &nbsp; &nbsp; &nbsp;}</p>
<p> &nbsp; &nbsp;}</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Tamir Khason</title>
		<link>http://khason.net/blog/never-ever-close-me-how-to-disable-close-button-in-wpf/comment-page-1/#comment-796</link>
		<dc:creator>Tamir Khason</dc:creator>
		<pubDate>Thu, 01 Jan 2009 08:23:46 +0000</pubDate>
		<guid isPermaLink="false">http://khason.net/blog/never-ever-close-me-how-to-disable-close-button-in-wpf/#comment-796</guid>
		<description>&lt;p&gt;Gagan, thank you for response. The point in this article is not to prevent the window from closing, but disable close button in the window system menu&lt;/p&gt;
</description>
		<content:encoded><![CDATA[<p>Gagan, thank you for response. The point in this article is not to prevent the window from closing, but disable close button in the window system menu</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Just code - Tamir Khason</title>
		<link>http://khason.net/blog/never-ever-close-me-how-to-disable-close-button-in-wpf/comment-page-1/#comment-795</link>
		<dc:creator>Just code - Tamir Khason</dc:creator>
		<pubDate>Thu, 01 Jan 2009 08:23:45 +0000</pubDate>
		<guid isPermaLink="false">http://khason.net/blog/never-ever-close-me-how-to-disable-close-button-in-wpf/#comment-795</guid>
		<description>&lt;p&gt;Challenge: create visual clipboard watcher, that displays and saves Bitmaps right after they arrives&lt;/p&gt;
</description>
		<content:encoded><![CDATA[<p>Challenge: create visual clipboard watcher, that displays and saves Bitmaps right after they arrives</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Ron</title>
		<link>http://khason.net/blog/never-ever-close-me-how-to-disable-close-button-in-wpf/comment-page-1/#comment-794</link>
		<dc:creator>Ron</dc:creator>
		<pubDate>Thu, 01 Jan 2009 08:23:44 +0000</pubDate>
		<guid isPermaLink="false">http://khason.net/blog/never-ever-close-me-how-to-disable-close-button-in-wpf/#comment-794</guid>
		<description>&lt;p&gt;Great post. &#160;Please add:&lt;/p&gt;
&lt;p&gt;using System.Windows.Interop;&lt;/p&gt;
&lt;p&gt;using System.Runtime.InteropServices;&lt;/p&gt;
</description>
		<content:encoded><![CDATA[<p>Great post. &nbsp;Please add:</p>
<p>using System.Windows.Interop;</p>
<p>using System.Runtime.InteropServices;</p>
]]></content:encoded>
	</item>
</channel>
</rss>
