<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	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/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>tewari &#187; C#</title>
	<atom:link href="http://www.tewari.info/category/c-sharp/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.tewari.info</link>
	<description>Professional Software Development by Ash Tewari</description>
	<lastBuildDate>Thu, 03 Jun 2010 01:52:16 +0000</lastBuildDate>
	
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>Win Advanced MVVM Book</title>
		<link>http://www.tewari.info/2010/05/09/win-advanced-mvvm-book/</link>
		<comments>http://www.tewari.info/2010/05/09/win-advanced-mvvm-book/#comments</comments>
		<pubDate>Mon, 10 May 2010 03:33:06 +0000</pubDate>
		<dc:creator>tewari</dc:creator>
				<category><![CDATA[C#]]></category>
		<category><![CDATA[WPF]]></category>
		<category><![CDATA[code]]></category>
		<category><![CDATA[xaml]]></category>
		<category><![CDATA[CodeCamp]]></category>
		<category><![CDATA[mvvm]]></category>
		<category><![CDATA[speaking]]></category>

		<guid isPermaLink="false">http://www.tewari.info/?p=200</guid>
		<description><![CDATA[	I am presenting a session on Building WPF Application using MVVM (Model-View-ViewModel) on May 15th at the Carolina Code Camp 2010.
	I will dissect a Sample WPF MVVM application and then highlight the most important aspects of the MVVM by coding a brand new ViewModel and incorporating it into the application. You will learn about the [...]]]></description>
			<content:encoded><![CDATA[	<p><a href="../library/josh-smith/advanced-mvvm/"><img class="alignleft" title="Advanced MVVM Cover" src="http://www.tewari.info/wp-content/advancedmvvmcover.jpg" alt="Advanced MVVM Cover" width="246" height="320" /></a>I am presenting a session on Building WPF Application using MVVM (<a title="Wikipedia-MVVM" href="http://en.wikipedia.org/wiki/Model_View_ViewModel">Model-View-ViewModel</a>) on May 15th at the <a title="Carolina Code Camp 2010" href="http://codecamp.developersguild.org/">Carolina Code Camp</a> 2010.</p>
	<p>I will dissect a Sample WPF MVVM application and then highlight the most important aspects of the MVVM by coding a brand new ViewModel and incorporating it into the application. You will learn about the Roles of the MVVM triad, the advantages of using MVVM and Characteristics of the ViewModel.</p>
	<p>Attendees will be eligible to win <del datetime="2010-06-02T01:39:18+00:00">two copies</del> one copy (see below) of <a title="Josh Smith" href="http://joshsmithonwpf.wordpress.com/">Josh Smith&#8217;s</a> <a title="advanced-mvvm-book" href="http://joshsmithonwpf.wordpress.com/advanced-mvvm/">Advanced MVVM book</a> as well as a few other WPF Books.</p>
	<p><em>{ I will be giving away one hard copy version of the book instead of digital versions due to concerns about DRM protection and unclear gift guidelines at lulu.com }</em>.</p>
	<p>And the winner is &#8230; Mark Freeman !!! Congratulations Mark, your copy of &#8220;Advanced MVVM&#8221; is on its way. Thanks for attending the code camp and your feedback.<br />
<hr/>Copyright &copy; 2010 <strong><a href="http://www.tewari.info">tewari</a></strong>. This Feed is for personal non-commercial use only. If you are not reading this material in your news aggregator, the site you are looking at is guilty of copyright infringement. Please contact legal@tewari.info so we can take legal action immediately.<br/><span style="float: right;font-size: 7pt"><a href="http://blog.taragana.com/index.php/archive/wordpress-plugins-provided-by-taraganacom/">Plugin</a> by <a href="http://www.taragana.com/">Taragana</a></span>
</p>
<p class="akst_link"><a href="http://www.tewari.info/?p=200&amp;akst_action=share-this"  title="E-mail this, post to del.icio.us, etc." id="akst_link_200" class="akst_share_link" rel="nofollow">Share This</a>
</p>]]></content:encoded>
			<wfw:commentRss>http://www.tewari.info/2010/05/09/win-advanced-mvvm-book/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Using Model-View-ViewModel in WPF Applications</title>
		<link>http://www.tewari.info/2010/01/25/using-model-view-viewmodel-in-wpf-applications/</link>
		<comments>http://www.tewari.info/2010/01/25/using-model-view-viewmodel-in-wpf-applications/#comments</comments>
		<pubDate>Mon, 25 Jan 2010 22:23:39 +0000</pubDate>
		<dc:creator>tewari</dc:creator>
				<category><![CDATA[C#]]></category>
		<category><![CDATA[WPF]]></category>
		<category><![CDATA[code]]></category>
		<category><![CDATA[xaml]]></category>
		<category><![CDATA[design pattern]]></category>
		<category><![CDATA[mvvm]]></category>
		<category><![CDATA[presentation]]></category>
		<category><![CDATA[socalcodecamp]]></category>

		<guid isPermaLink="false">http://www.tewari.info/?p=155</guid>
		<description><![CDATA[	I am presenting at SoCalCodeCamp this weekend (January 30th, 2010) - Advanced WPF &#8211; Using Model-View-ViewModel in WPF Applications.
	Agenda :
	1. Roles of the M-V-VM triad
	2. Why use M-V-VM ?
	3. Characteristics of the ViewModel
	4. Build a Sample WPF Application using M-V-VM
	
	Resources :
	
	MSDN Magazine Article and Sample Application Download
	Martin Fowler’s  description of the ‘Presentation Model ‘
	Jeremy [...]]]></description>
			<content:encoded><![CDATA[	<div class="mceTemp">I am presenting at <a title="socalcodecamp website" href="http://www.socalcodecamp.com/" target="_self">SoCalCodeCamp</a> this weekend (January 30th, 2010) -<a title="WPF MVVM Presntation " href="http://www.socalcodecamp.com/socalcodecamp/session.aspx?sid=0b2ee44f-595d-4f55-a5d6-2b1293f546d0" target="_self"> Advanced WPF &#8211; Using Model-View-ViewModel in WPF Applications</a>.</div>
	<p><div id="attachment_156" class="wp-caption alignnone" style="width: 460px"><img class="size-full wp-image-156" title="Sample WPF App - TaskList" src="http://www.tewari.info/wp-content/tasklist.png" alt="tasklist-mockup" width="450" height="256" /><p class="wp-caption-text">tasklist-mockup</p></div></p>
	<p>Agenda :</p>
	<div>1. Roles of the M-V-VM triad</div>
	<div>2. Why use M-V-VM ?</div>
	<div>3. Characteristics of the ViewModel</div>
	<div>4. Build a Sample WPF Application using M-V-VM</div>
	<p></br></br></p>
	<p>Resources :</p>
	<ol>
	<li><a title="MSDN Magazine Article" href="http://msdn.microsoft.com/en-us/magazine/dd419663.aspx">MSDN Magazine Article</a> and Sample Application <a title="Download Demo Application Code" href="http://code.msdn.microsoft.com/mag200902MVVM/Release/ProjectReleases.aspx">Download</a></li>
	<li><a title="MartinFowler.com" href="http://martinfowler.com/eaaDev/PresentationModel.html">Martin Fowler’s  description of the ‘Presentation Model ‘</a></li>
	<li><a title="Jeremy Miller's - Build Your CAB" href="http://codebetter.com/blogs/jeremy.miller/archive/2007/07/25/the-build-your-own-cab-series-table-of-contents.aspx">Jeremy Miller’s ‘Build Your Own CAB’ series</a></li>
	</ol>
<hr/>Copyright &copy; 2010 <strong><a href="http://www.tewari.info">tewari</a></strong>. This Feed is for personal non-commercial use only. If you are not reading this material in your news aggregator, the site you are looking at is guilty of copyright infringement. Please contact legal@tewari.info so we can take legal action immediately.<br/><span style="float: right;font-size: 7pt"><a href="http://blog.taragana.com/index.php/archive/wordpress-plugins-provided-by-taraganacom/">Plugin</a> by <a href="http://www.taragana.com/">Taragana</a></span>
</p>
<p class="akst_link"><a href="http://www.tewari.info/?p=155&amp;akst_action=share-this"  title="E-mail this, post to del.icio.us, etc." id="akst_link_155" class="akst_share_link" rel="nofollow">Share This</a>
</p>]]></content:encoded>
			<wfw:commentRss>http://www.tewari.info/2010/01/25/using-model-view-viewmodel-in-wpf-applications/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Job Opening &#8211; Windows GUI Developer</title>
		<link>http://www.tewari.info/2009/03/09/job-opening-windows-gui-developer/</link>
		<comments>http://www.tewari.info/2009/03/09/job-opening-windows-gui-developer/#comments</comments>
		<pubDate>Mon, 09 Mar 2009 21:04:30 +0000</pubDate>
		<dc:creator>tewari</dc:creator>
				<category><![CDATA[C#]]></category>
		<category><![CDATA[career]]></category>
		<category><![CDATA[contract]]></category>
		<category><![CDATA[contract position]]></category>
		<category><![CDATA[job]]></category>
		<category><![CDATA[job opening]]></category>
		<category><![CDATA[Opening]]></category>
		<category><![CDATA[Windows]]></category>
		<category><![CDATA[windows developer]]></category>

		<guid isPermaLink="false">http://www.tewari.info/2009/03/09/job-opening-windows-gui-developer/</guid>
		<description><![CDATA[	We have a 3-4 month contract position open for a Windows GUI Developer in our group at Calabasas, California:
	
	2+ years experience developing C++/C# Windows thick-client applications
	Expert in GUI development on Windows
	Expert in Object Oriented Analysis and Design (OOA/OOD)
	Deep understanding of client-server software development
	Experience in multithreading, and thread synchronization
	Excellent communication skills (written and verbal)
	Highly organized and [...]]]></description>
			<content:encoded><![CDATA[	<p>We have a 3-4 month contract position open for a Windows GUI Developer in our group at<a href="http://maps.google.com/maps?q=calabasas,+CA&amp;oe=utf-8&amp;rls=org.mozilla:en-US:official&amp;client=firefox-a&amp;um=1&amp;ie=UTF-8&amp;split=0&amp;gl=us&amp;ei=SYK1SbXHGM-jtgf9jaXqDA&amp;sa=X&amp;oi=geocode_result&amp;resnum=1&amp;ct=title" title="calabasas-map" target="_blank"> Calabasas, California</a>:</p>
	<ul>
	<li>2+ years experience developing C++/C# Windows thick-client applications</li>
	<li>Expert in GUI development on Windows</li>
	<li>Expert in Object Oriented Analysis and Design (OOA/OOD)</li>
	<li>Deep understanding of client-server software development</li>
	<li>Experience in multithreading, and thread synchronization</li>
	<li>Excellent communication skills (written and verbal)</li>
	<li>Highly organized and detail oriented</li>
	<li>BSCS/BSEE or equivalent</li>
	</ul>
	<p>If you are interested, <a href="http://www.tewari.info/contact-me/" title="Contact Ash Tewari" target="_blank">contact me</a>. <strike>The position is available now.</strike><hr/>Copyright &copy; 2010 <strong><a href="http://www.tewari.info">tewari</a></strong>. This Feed is for personal non-commercial use only. If you are not reading this material in your news aggregator, the site you are looking at is guilty of copyright infringement. Please contact legal@tewari.info so we can take legal action immediately.<br/><span style="float: right;font-size: 7pt"><a href="http://blog.taragana.com/index.php/archive/wordpress-plugins-provided-by-taraganacom/">Plugin</a> by <a href="http://www.taragana.com/">Taragana</a></span>
</p>
<p class="akst_link"><a href="http://www.tewari.info/?p=48&amp;akst_action=share-this"  title="E-mail this, post to del.icio.us, etc." id="akst_link_48" class="akst_share_link" rel="nofollow">Share This</a>
</p>]]></content:encoded>
			<wfw:commentRss>http://www.tewari.info/2009/03/09/job-opening-windows-gui-developer/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Dial Gauge is a ProgressBar</title>
		<link>http://www.tewari.info/2008/06/10/dial-gauge-is-a-progressbar/</link>
		<comments>http://www.tewari.info/2008/06/10/dial-gauge-is-a-progressbar/#comments</comments>
		<pubDate>Wed, 11 Jun 2008 06:49:43 +0000</pubDate>
		<dc:creator>tewari</dc:creator>
				<category><![CDATA[C#]]></category>
		<category><![CDATA[WPF]]></category>
		<category><![CDATA[code]]></category>
		<category><![CDATA[xaml]]></category>
		<category><![CDATA[.NET]]></category>
		<category><![CDATA[Dial]]></category>
		<category><![CDATA[Gauge]]></category>
		<category><![CDATA[ProgressBar]]></category>

		<guid isPermaLink="false">http://www.tewari.info/2008/06/10/dial-gauge-is-a-progressbar/</guid>
		<description><![CDATA[	I am not just being philosophical here. In WPF, ControlTemplates allow you to transform a control&#8217;s appearance. This is not the same as applying stylesheets. This is an entirely new level of customization. What you see in the screenshot below looks like a Dial but is actually a simple  ProgressBar control wearing a &#8220;Dial&#8221; [...]]]></description>
			<content:encoded><![CDATA[	<p>I am not just being philosophical here. In <a href="http://msdn.microsoft.com/en-us/netframework/aa663326.aspx" title="MSDN-WPF" target="_blank">WPF</a>, <a href="http://msdn.microsoft.com/en-us/magazine/cc163497.aspx" title="Using Templates to Customize WPF Controls" target="_blank">ControlTemplates </a>allow you to transform a control&#8217;s appearance. This is not the same as applying stylesheets. This is an entirely new level of customization. What you see in the screenshot below looks like a Dial but is actually a simple  ProgressBar control wearing a &#8220;Dial&#8221; template. The Dial template was created using <a href="http://www.microsoft.com/expression/products/Overview.aspx?key=blend" title="Microsoft-Expression-Blend" target="_blank">Microsoft Expression Blend</a> .</p>
	<p><img src="http://www.tewari.info/images/dial-is-a-progressbar.PNG" alt="dial-is-a-progressbar.PNG" height="483" width="566" /></p>
	<p>Include the ControlTemplate as a Window.Resource and then assign it to ProgressBar element&#8217;s Template attribute :</p>
	<pre name="code" class="xml">
        <ProgressBar x:Name=\"pBar\" Template=\"{StaticResource templateDial}\"
                     Minimum=\"0\" Maximum=\"270\" Margin=\"0\" />
</pre>
	<p>Of course that is not all. The ControlTemplate must define some named elements of  FrameworkElement type. Charles Petzold has explained it in detail : <a href="http://msdn.microsoft.com/en-us/magazine/cc163497.aspx" title="Charles-Petzold-Using Templates to Customize WPF Controls" target="_blank">MSDN Magazine Article</a>. So, I will not repeat it here.</p>
	<p>The sample code can be downloaded here : <a href="http://www.tewari.info/downloads/DialTest.zip" title="DialTest.zip" target="_blank">DialTest.zip</a><br />
License : <a href="http://creativecommons.org/licenses/by-nc-sa/3.0/us/" rel="license">Creative Commons Attribution-Noncommercial-Share Alike 3.0 United States License.</a><hr/>Copyright &copy; 2010 <strong><a href="http://www.tewari.info">tewari</a></strong>. This Feed is for personal non-commercial use only. If you are not reading this material in your news aggregator, the site you are looking at is guilty of copyright infringement. Please contact legal@tewari.info so we can take legal action immediately.<br/><span style="float: right;font-size: 7pt"><a href="http://blog.taragana.com/index.php/archive/wordpress-plugins-provided-by-taraganacom/">Plugin</a> by <a href="http://www.taragana.com/">Taragana</a></span>
</p>
<p class="akst_link"><a href="http://www.tewari.info/?p=38&amp;akst_action=share-this"  title="E-mail this, post to del.icio.us, etc." id="akst_link_38" class="akst_share_link" rel="nofollow">Share This</a>
</p>]]></content:encoded>
			<wfw:commentRss>http://www.tewari.info/2008/06/10/dial-gauge-is-a-progressbar/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>PostSharp with SharpDevelop</title>
		<link>http://www.tewari.info/2008/04/28/postsharp-with-sharpdevelop/</link>
		<comments>http://www.tewari.info/2008/04/28/postsharp-with-sharpdevelop/#comments</comments>
		<pubDate>Tue, 29 Apr 2008 05:04:43 +0000</pubDate>
		<dc:creator>tewari</dc:creator>
				<category><![CDATA[AOP]]></category>
		<category><![CDATA[C#]]></category>
		<category><![CDATA[code]]></category>
		<category><![CDATA[Aspect]]></category>
		<category><![CDATA[MSBuild]]></category>
		<category><![CDATA[PostSharp]]></category>
		<category><![CDATA[SharpDevelop]]></category>

		<guid isPermaLink="false">http://www.tewari.info/2008/04/28/postsharp-with-sharpdevelop/</guid>
		<description><![CDATA[	SharpDevelop3.0 uses MSBuild. Including PostSharp in your build process is transparent if you are doing a global install using PostSharp installer. If you are doing a per-project installation using &#8220;Binary &#8211; No Installer&#8221; download, you will need to import the PostSharp targets into your .csproj file -
	
	
    True

	C:\code\PostSharp-1.0.8.316-Binary\


	For more details, read the [...]]]></description>
			<content:encoded><![CDATA[	<p><a href="http://sharpdevelop.net/OpenSource/SD/Default.aspx" title="SharpDevelop HomePage" target="_blank">SharpDevelop3.0</a> uses <a href="http://en.wikipedia.org/wiki/MSBuild" title="MSBuild on wikipedia" target="_blank">MSBuild</a>. Including PostSharp in your build process is transparent if you are doing a global install using PostSharp installer. If you are doing a per-project installation using &#8220;Binary &#8211; No Installer&#8221; <a href="http://www.postsharp.org/download/" title="postsharp download" target="_blank">download</a>, you will need to import the PostSharp targets into your .csproj file -</p>
	<pre name="code" class="xml">
	<propertygroup>
    <dontimportpostsharp>True</dontimportpostsharp>
</propertygroup>
	<postsharpdirectory>C:\code\PostSharp-1.0.8.316-Binary\</postsharpdirectory>
<import project=\"$(MSBuildBinPath)\Microsoft.CSharp.targets\"></import>
<import project=\"$(PostSharpDirectory)PostSharp.targets\"></import></pre>
	<p>For more details, read the install instructions included in the PostSharp <a href="http://www.postsharp.org/download/" title="postsharp download" target="_blank">download </a>and <a href="http://www.postsharp.org/blog/2008/01/under-hood-of-msbuild-integration.html" title="under-hood-of-msbuild-integration" target="_blank">under-the-hood-of-msbuild-integration</a>.</p>
	<p>To use local PostSharp binaries (relative to your project) , modify your .csproj file as follows -</p>
	<pre name="code" class="xml">
  <PropertyGroup Condition=\" Exists('PostSharp\PostSharp.targets') \">
    <DontImportPostSharp>True</DontImportPostSharp>
    <PostSharpDirectory>$(MSBuildProjectDirectory)\PostSharp\</PostSharpDirectory>
  </PropertyGroup>
	
  <Import Project=\"$(MSBuildBinPath)\Microsoft.CSharp.targets\" />
	
  <Import Project=\"$(PostSharpDirectory)PostSharp.targets\"
  Condition=\" Exists('$(PostSharpDirectory)PostSharp.targets') \" />
</pre>
	<p>$(MSBuildProjectDirectory) is the directory containing your .csproj file.<br />
\PostSharp\ is the directory containing local PostSharp binaries.</p>
	<p>2. You will need to exclude the Aspect class itself from being woven.</p>
	<p>If you are following the <a href="http://www.postsharp.org/about/getting-started/" title="getting-started-sample" target="_blank">getting-started sample</a>, see the following example:</p>
	<pre name="code" class="csharp">
[Serializable]
[Trace( null, AttributeExclude = true )]
public sealed class TraceAttribute : OnMethodBoundaryAspect
{</pre>
	<p>3. Compile your project.<hr/>Copyright &copy; 2010 <strong><a href="http://www.tewari.info">tewari</a></strong>. This Feed is for personal non-commercial use only. If you are not reading this material in your news aggregator, the site you are looking at is guilty of copyright infringement. Please contact legal@tewari.info so we can take legal action immediately.<br/><span style="float: right;font-size: 7pt"><a href="http://blog.taragana.com/index.php/archive/wordpress-plugins-provided-by-taraganacom/">Plugin</a> by <a href="http://www.taragana.com/">Taragana</a></span>
</p>
<p class="akst_link"><a href="http://www.tewari.info/?p=35&amp;akst_action=share-this"  title="E-mail this, post to del.icio.us, etc." id="akst_link_35" class="akst_share_link" rel="nofollow">Share This</a>
</p>]]></content:encoded>
			<wfw:commentRss>http://www.tewari.info/2008/04/28/postsharp-with-sharpdevelop/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Using Custom Converter in XAML</title>
		<link>http://www.tewari.info/2008/04/15/using-custom-converter-in-xaml/</link>
		<comments>http://www.tewari.info/2008/04/15/using-custom-converter-in-xaml/#comments</comments>
		<pubDate>Wed, 16 Apr 2008 05:22:12 +0000</pubDate>
		<dc:creator>tewari</dc:creator>
				<category><![CDATA[C#]]></category>
		<category><![CDATA[WPF]]></category>
		<category><![CDATA[code]]></category>
		<category><![CDATA[xaml]]></category>
		<category><![CDATA[Binding]]></category>
		<category><![CDATA[ImageDataConverter]]></category>
		<category><![CDATA[ListView]]></category>

		<guid isPermaLink="false">http://www.tewari.info/2008/04/15/using-custom-converter-in-xaml/</guid>
		<description><![CDATA[	In my previous post : WPF-LINQ To SQL Sample, I had to resort to modifying .dbml file to get the images stored as varbinary into the WPF ListView control. I had to change the Type of image fields to System.Byte[], instead of using System.Data.Linq.Binary. A better way to do this is to use a custom [...]]]></description>
			<content:encoded><![CDATA[	<p>In my previous post : <a href="http://www.tewari.info/2008/03/07/wpf-linq-to-sql-sample/" title="wpf-linq-to-sql-sample" target="_blank">WPF-LINQ To SQL Sample</a>, I had to resort to modifying .dbml file to get the images stored as varbinary into the WPF ListView control. I had to change the Type of image fields to System.Byte[], instead of using System.Data.Linq.Binary. A better way to do this is to use a custom converter. WPF allows you    to specify custom converter as part of the Binding in .xaml, like this -</p>
	<pre name="code" class="xml">
&lt;Image Grid.Row=\"2\"
Source=\"{Binding Path=ThumbNailPhoto ,
Converter={StaticResource imageConverter}}\"&gt;&lt;/Image&gt;</pre>
	<p>The custom converter is declared in the same .xaml file as a resource -</p>
	<pre name="code" class="xml">
&lt;Window.Resources&gt;
&lt;local:ImageDataConverter x:Key=\"imageConverter\" /&gt;
&lt;/Window.Resources&gt;</pre>
	<p>ImageDataConverter is implemented in .xaml.cs file -</p>
	<pre name="code" class="csharp">
public class ImageDataConverter : IValueConverter
{
   public object Convert(object value, Type targetType, object parameter,
   System.Globalization.CultureInfo culture)
   {
      byte[] image = ((System.Data.Linq.Binary)value).ToArray();
      return image;
   }
	
   public object ConvertBack(object value, Type targetType, object parameter,
   System.Globalization.CultureInfo culture)
   {
      throw new NotSupportedException();
   }
}</pre>
	<p>The updated sample code can be downloaded here : <a href="http://www.tewari.info/downloads/Linq2SqlSample2.zip" title="Linq2SqlSample2.zip" target="_blank">WPF-LINQ to SQL Sample</a><br />
License : <a href="http://creativecommons.org/licenses/by-nc-sa/3.0/us/" rel="license">Creative Commons Attribution-Noncommercial-Share Alike 3.0 United States License.</a><hr/>Copyright &copy; 2010 <strong><a href="http://www.tewari.info">tewari</a></strong>. This Feed is for personal non-commercial use only. If you are not reading this material in your news aggregator, the site you are looking at is guilty of copyright infringement. Please contact legal@tewari.info so we can take legal action immediately.<br/><span style="float: right;font-size: 7pt"><a href="http://blog.taragana.com/index.php/archive/wordpress-plugins-provided-by-taraganacom/">Plugin</a> by <a href="http://www.taragana.com/">Taragana</a></span>
</p>
<p class="akst_link"><a href="http://www.tewari.info/?p=34&amp;akst_action=share-this"  title="E-mail this, post to del.icio.us, etc." id="akst_link_34" class="akst_share_link" rel="nofollow">Share This</a>
</p>]]></content:encoded>
			<wfw:commentRss>http://www.tewari.info/2008/04/15/using-custom-converter-in-xaml/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>WPF &#8211; LINQ to SQL Sample</title>
		<link>http://www.tewari.info/2008/03/07/wpf-linq-to-sql-sample/</link>
		<comments>http://www.tewari.info/2008/03/07/wpf-linq-to-sql-sample/#comments</comments>
		<pubDate>Fri, 07 Mar 2008 07:15:35 +0000</pubDate>
		<dc:creator>tewari</dc:creator>
				<category><![CDATA[C#]]></category>
		<category><![CDATA[LINQ]]></category>
		<category><![CDATA[WPF]]></category>
		<category><![CDATA[code]]></category>
		<category><![CDATA[database]]></category>
		<category><![CDATA[sql]]></category>
		<category><![CDATA[.NET]]></category>
		<category><![CDATA[AdventureWorks]]></category>
		<category><![CDATA[control]]></category>
		<category><![CDATA[DataBinding]]></category>
		<category><![CDATA[demo]]></category>
		<category><![CDATA[ListView]]></category>
		<category><![CDATA[mapping]]></category>
		<category><![CDATA[sample]]></category>
		<category><![CDATA[Share]]></category>
		<category><![CDATA[Windows]]></category>
		<category><![CDATA[WPF-LINQ]]></category>

		<guid isPermaLink="false">http://www.tewari.info/2008/03/07/wpf-linq-to-sql-sample/</guid>
		<description><![CDATA[	This exercise in binding a WPF ListView control with LINQ to SQL was a lot of fun ! The following image shows data from AdventureWorks sample database displayed in the ListView control. The end result is very admirable, even in this very basic demo. Feeling a complete sense of freedom is unavoidable when working with [...]]]></description>
			<content:encoded><![CDATA[	<p>This exercise in binding a WPF ListView control with LINQ to SQL was a lot of fun ! The following image shows data from <a href="http://www.codeplex.com/MSFTDBProdSamples" title="MSSQL Sample Databases" target="_blank">AdventureWorks </a>sample database displayed in the ListView control. The end result is very admirable, even in this very basic demo. Feeling a complete sense of freedom is unavoidable when working with WPF.</p>
	<p><img src="http://www.tewari.info/images/Linq2SqlSample1.Png" alt="Linq2SqlSample1.Png" height="390" width="555" /></p>
	<p>This sample demonstrates :</p>
	<ol>
	<li>LINQ to SQL mapping.</li>
	<li>WPF ListView Control DataBinding.</li>
	<li>Displaying images stored in database as varbinary in WPF control.</li>
	</ol>
	<p>The sample code can be downloaded here : <a href="http://www.tewari.info/downloads/Linq2SqlSample.zip" title="Linq2SqlSample.zip" target="_blank">WPF-LINQ to SQL Sample</a><br />
License : <a href="http://creativecommons.org/licenses/by-nc-sa/3.0/us/" rel="license">Creative Commons Attribution-Noncommercial-Share Alike 3.0 United States License.</a></p>
	<p><a href="http://creativecommons.org/licenses/by-nc-sa/3.0/us/" rel="license"><img src="http://i.creativecommons.org/l/by-nc-sa/3.0/us/88x31.png" alt="Creative Commons License" style="border-width: 0pt" /></a><hr/>Copyright &copy; 2010 <strong><a href="http://www.tewari.info">tewari</a></strong>. This Feed is for personal non-commercial use only. If you are not reading this material in your news aggregator, the site you are looking at is guilty of copyright infringement. Please contact legal@tewari.info so we can take legal action immediately.<br/><span style="float: right;font-size: 7pt"><a href="http://blog.taragana.com/index.php/archive/wordpress-plugins-provided-by-taraganacom/">Plugin</a> by <a href="http://www.taragana.com/">Taragana</a></span>
</p>
<p class="akst_link"><a href="http://www.tewari.info/?p=33&amp;akst_action=share-this"  title="E-mail this, post to del.icio.us, etc." id="akst_link_33" class="akst_share_link" rel="nofollow">Share This</a>
</p>]]></content:encoded>
			<wfw:commentRss>http://www.tewari.info/2008/03/07/wpf-linq-to-sql-sample/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Customize log4net Output Path</title>
		<link>http://www.tewari.info/2008/03/06/customize-log4net-output-path/</link>
		<comments>http://www.tewari.info/2008/03/06/customize-log4net-output-path/#comments</comments>
		<pubDate>Fri, 07 Mar 2008 00:56:55 +0000</pubDate>
		<dc:creator>tewari</dc:creator>
				<category><![CDATA[C#]]></category>
		<category><![CDATA[code]]></category>
		<category><![CDATA[log4net]]></category>
		<category><![CDATA[tips]]></category>
		<category><![CDATA[output path]]></category>
		<category><![CDATA[RollingFileAppender]]></category>
		<category><![CDATA[startup directory]]></category>

		<guid isPermaLink="false">http://www.tewari.info/2008/03/06/customize-log4net-output-path/</guid>
		<description><![CDATA[	 The default log4net output path is relative to the startup directory of your executable. To customize the output path, you can override the base Appender&#8217;s File property in your own Appender class. The following example describes how to route the log files relative to the temp folder :
	
   public class MyOwnAppender : [...]]]></description>
			<content:encoded><![CDATA[	<p> The default log4net output path is relative to the startup directory of your executable. To customize the output path, you can override the base Appender&#8217;s File property in your own Appender class. The following example describes how to route the log files relative to the temp folder :</p>
	<pre name="code" class="csharp">
   public class MyOwnAppender : log4net.Appender.RollingFileAppender
   {
         public override string File
         {
             get
             {
                 return base.File;
             }
	
            set
            {
                if (Path.IsPathRooted(value))
                {
                    base.File = value;
                }
                else
                {
                    base.File = Path.Combine(Path.GetTempPath(), value);
                }
            }
        }
    }
</pre>
	<p>Your log4net config file must be modified so that log4net can locate and use your custom Appender. If MyOwnAppender is in MyNamespace and you have implemented it in MyLoggerLib.dll :</p>
	<pre name="code" class="xml">
<appender name=\"myFileAppender\" type=\"MyNamespace.MyOwnAppender, MyLoggerLib\">
</pre>
<hr/>Copyright &copy; 2010 <strong><a href="http://www.tewari.info">tewari</a></strong>. This Feed is for personal non-commercial use only. If you are not reading this material in your news aggregator, the site you are looking at is guilty of copyright infringement. Please contact legal@tewari.info so we can take legal action immediately.<br/><span style="float: right;font-size: 7pt"><a href="http://blog.taragana.com/index.php/archive/wordpress-plugins-provided-by-taraganacom/">Plugin</a> by <a href="http://www.taragana.com/">Taragana</a></span>
</p>
<p class="akst_link"><a href="http://www.tewari.info/?p=30&amp;akst_action=share-this"  title="E-mail this, post to del.icio.us, etc." id="akst_link_30" class="akst_share_link" rel="nofollow">Share This</a>
</p>]]></content:encoded>
			<wfw:commentRss>http://www.tewari.info/2008/03/06/customize-log4net-output-path/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Database Schema Version Control Tool</title>
		<link>http://www.tewari.info/2008/02/18/dbupdater-database-schema-version-control/</link>
		<comments>http://www.tewari.info/2008/02/18/dbupdater-database-schema-version-control/#comments</comments>
		<pubDate>Tue, 19 Feb 2008 03:05:52 +0000</pubDate>
		<dc:creator>tewari</dc:creator>
				<category><![CDATA[C#]]></category>
		<category><![CDATA[database]]></category>
		<category><![CDATA[freeware]]></category>
		<category><![CDATA[sql]]></category>
		<category><![CDATA[version-control]]></category>
		<category><![CDATA[best practices]]></category>
		<category><![CDATA[change]]></category>
		<category><![CDATA[code]]></category>
		<category><![CDATA[database schema]]></category>
		<category><![CDATA[Databases]]></category>
		<category><![CDATA[DBMS]]></category>
		<category><![CDATA[DbUpdater]]></category>
		<category><![CDATA[Design]]></category>
		<category><![CDATA[Download]]></category>
		<category><![CDATA[Evolutionary]]></category>
		<category><![CDATA[free tool]]></category>
		<category><![CDATA[MSSQL]]></category>
		<category><![CDATA[NHibernate]]></category>
		<category><![CDATA[process]]></category>
		<category><![CDATA[schema]]></category>
		<category><![CDATA[schema version]]></category>
		<category><![CDATA[SchemaVersionsLog]]></category>
		<category><![CDATA[Scripts]]></category>
		<category><![CDATA[sql scripts]]></category>
		<category><![CDATA[table]]></category>
		<category><![CDATA[tool]]></category>
		<category><![CDATA[version]]></category>
		<category><![CDATA[version control tool]]></category>
		<category><![CDATA[Versioning]]></category>

		<guid isPermaLink="false">http://www.tewari.info/2008/02/18/dbupdater-database-schema-version-control/</guid>
		<description><![CDATA[	It is essential to treat database schema as source code  and apply all the norms and best practices applicable to it. From what I hear  and read, database schema version control is non-existent in too many  projects.
	Various techniques to accomplish version control of  database schemas have been discussed and published. Martin [...]]]></description>
			<content:encoded><![CDATA[	<p designtimesp="18554">It is essential to treat database schema as source code  and apply all the norms and best practices applicable to it. From what I hear  and read, database schema version control is non-existent in too many  projects.</p>
	<p designtimesp="18555">Various techniques to accomplish version control of  database schemas have been discussed and published. Martin Fowler and Pramod  Sadagale has written a comprehensive article on <a href="http://martinfowler.com/articles/evodb.html" designtimesp="18556">Evolutionary Database  Design</a>. It is a must-read for everyone involved with database  development.</p>
	<p designtimesp="18562">K. Scott Allen writes in detail about an  excellent system here &#8211; <a href="http://odetocode.com/Blogs/scott/archive/2008/02/02/11721.aspx" title="Versioning Databases - Change Scripts" designtimesp="18561">Versioning Databases &#8211; Change Scripts</a>. This approach  is sufficiently light-weight (for my taste) and provides complete control over  the whole process.</p>
	<p designtimesp="18562">I am providing a free tool here that you can use to  implement this system. It will even create the SchemaVersionsLog table for your  database, if it doesn&#8217;t exist. If you are using this tool with MSSQL Server, you  can get started with very little effort. If you are using a different DBMS, you  can still use this tool. It uses NHibernate to access the SchemaVersionsLog  table. So, any DBMS supported by NHibernate is acceptable, as long as it comes with a command line tool to execute the sql scripts.</p>
	<p designtimesp="18562">Download <a href="http://www.tewari.info/dbupdater/" title="DbUpdater : Database Schema Version Control" target="_blank">DbUpdater here</a>.</p>
<hr/>Copyright &copy; 2010 <strong><a href="http://www.tewari.info">tewari</a></strong>. This Feed is for personal non-commercial use only. If you are not reading this material in your news aggregator, the site you are looking at is guilty of copyright infringement. Please contact legal@tewari.info so we can take legal action immediately.<br/><span style="float: right;font-size: 7pt"><a href="http://blog.taragana.com/index.php/archive/wordpress-plugins-provided-by-taraganacom/">Plugin</a> by <a href="http://www.taragana.com/">Taragana</a></span>
</p>
<p class="akst_link"><a href="http://www.tewari.info/?p=17&amp;akst_action=share-this"  title="E-mail this, post to del.icio.us, etc." id="akst_link_17" class="akst_share_link" rel="nofollow">Share This</a>
</p>]]></content:encoded>
			<wfw:commentRss>http://www.tewari.info/2008/02/18/dbupdater-database-schema-version-control/feed/</wfw:commentRss>
		<slash:comments>5</slash:comments>
		</item>
	</channel>
</rss>
