<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="http://weblogs.asp.net/utility/FeedStylesheets/atom.xsl" media="screen"?><feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en"><title type="html">Darren Sim's Code Focus Blog</title><subtitle type="html" /><id>http://weblogs.asp.net/darrensim/atom.aspx</id><link rel="alternate" type="text/html" href="http://weblogs.asp.net/darrensim/default.aspx" /><link rel="self" type="application/atom+xml" href="http://weblogs.asp.net/darrensim/atom.aspx" /><generator uri="http://communityserver.org" version="3.0.20510.895">Community Server</generator><updated>2008-06-29T08:38:00Z</updated><entry><title>Great post on "Staffing in a recession"</title><link rel="alternate" type="text/html" href="http://weblogs.asp.net/darrensim/archive/2009/05/29/great-post-on-quot-staffing-in-a-recession-quot.aspx" /><id>http://weblogs.asp.net/darrensim/archive/2009/05/29/great-post-on-quot-staffing-in-a-recession-quot.aspx</id><published>2009-05-28T21:43:00Z</published><updated>2009-05-28T21:43:00Z</updated><content type="html">&lt;P mce_keep="true"&gt;I was reading through the CIO Insight website and came across a really insightful article "&lt;STRONG&gt;&lt;EM&gt;Problems and Promise of Staffing in a Recession&lt;/EM&gt;&lt;/STRONG&gt;" which I think is something that's very nice for developers and managers alike to understand. =)&lt;/P&gt;
&lt;P mce_keep="true"&gt;&lt;A href="http://blogs.cioinsight.com/knowitall/content001/careers/problems_and_promise_of_staffing_in_a_recession.html?kc=CIOQUICKNL05282009MOD1"&gt;http://blogs.cioinsight.com/knowitall/content001/careers/problems_and_promise_of_staffing_in_a_recession.html?kc=CIOQUICKNL05282009MOD1&lt;/A&gt;&lt;/P&gt;
&lt;P mce_keep="true"&gt;&amp;nbsp;&lt;/P&gt;&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=7101169" width="1" height="1"&gt;</content><author><name>Darren.Sim</name><uri>http://weblogs.asp.net/members/Darren.Sim.aspx</uri></author><category term="Careers" scheme="http://weblogs.asp.net/darrensim/archive/tags/Careers/default.aspx" /><category term="Management" scheme="http://weblogs.asp.net/darrensim/archive/tags/Management/default.aspx" /></entry><entry><title>Book Review - ASP.NET 3.5 Ajax</title><link rel="alternate" type="text/html" href="http://weblogs.asp.net/darrensim/archive/2009/03/06/book-review-asp-net-3-5-ajax.aspx" /><id>http://weblogs.asp.net/darrensim/archive/2009/03/06/book-review-asp-net-3-5-ajax.aspx</id><published>2009-03-05T19:08:00Z</published><updated>2009-03-05T19:08:00Z</updated><content type="html">&lt;p&gt;&amp;nbsp;&lt;img src="http://media.wiley.com/product_data/coverImage/77/04703921/0470392177.jpg" mce_src="http://media.wiley.com/product_data/coverImage/77/04703921/0470392177.jpg" width="100" height="126"&gt; &lt;/p&gt;&lt;p&gt;I've recently received a complimentary of the Professional ASP.NET 3.5 Ajax book by WROX authored by several big names in .NET Web Development, such as Bill Evjen, Matt Gibbs, Dan Wahlin and Dave Reed. Of this list, Matt's from the team that developed the technology itself.&lt;/p&gt;&lt;p&gt;I was very surprised to find this book so well written for all levels of readers, with a very good description of AJAX history and concepts as well as more indepth topics. Certainly a great book to add onto your book shelve if you want to get up to speed with ASP.NET Ajax fast.&lt;br&gt;&lt;/p&gt;&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=6939285" width="1" height="1"&gt;</content><author><name>Darren.Sim</name><uri>http://weblogs.asp.net/members/Darren.Sim.aspx</uri></author><category term="AJAX" scheme="http://weblogs.asp.net/darrensim/archive/tags/AJAX/default.aspx" /><category term="ASP.NET" scheme="http://weblogs.asp.net/darrensim/archive/tags/ASP.NET/default.aspx" /></entry><entry><title>Mind Reading or Mind Boggling</title><link rel="alternate" type="text/html" href="http://weblogs.asp.net/darrensim/archive/2008/12/13/mind-reading-or-mind-boggling.aspx" /><id>http://weblogs.asp.net/darrensim/archive/2008/12/13/mind-reading-or-mind-boggling.aspx</id><published>2008-12-13T03:21:00Z</published><updated>2008-12-13T03:21:00Z</updated><content type="html">&lt;P mce_keep="true"&gt;Japanese researchers have developed a what&lt;EM&gt;&amp;nbsp;&lt;/EM&gt;I call a MIND BOGGLING technology of reading a human's mind, which can be transcribed into images. Basically, what they did was to take an image of brain activity taken in a functional MRI scanner,&amp;nbsp;re-creating&amp;nbsp;a&amp;nbsp;monotone image from scratch.&lt;/P&gt;
&lt;P mce_keep="true"&gt;&lt;IMG style="WIDTH: 300px; HEIGHT: 565px" height=565 src="http://www.newscientist.com/data/images/ns/cms/dn16267/dn16267-2_300.jpg" width=300 mce_src="http://www.newscientist.com/data/images/ns/cms/dn16267/dn16267-2_300.jpg"&gt;&lt;/P&gt;
&lt;P mce_keep="true"&gt;This technology would be great if put into good use and could spell disaster should it be fall into evil hands. Military covert operative might have to be re-trained all together on enemy captures and etc. However, if put into good use, this technology could also help us uncover our true innerselves through the dreams we make, or allowing the physically and/or&amp;nbsp;visually impaired to be better understood.&lt;/P&gt;
&lt;P mce_keep="true"&gt;More about this could be read at &lt;A href="http://www.newscientist.com/article/dn16267-mindreading-software-could-record-your-dreams.html"&gt;http://www.newscientist.com/article/dn16267-mindreading-software-could-record-your-dreams.html&lt;/A&gt;&lt;/P&gt;&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=6780698" width="1" height="1"&gt;</content><author><name>Darren.Sim</name><uri>http://weblogs.asp.net/members/Darren.Sim.aspx</uri></author><category term="Emerging Technology" scheme="http://weblogs.asp.net/darrensim/archive/tags/Emerging+Technology/default.aspx" /></entry><entry><title>Composite Application Guidance (CAG) for WPF (aka. Prism) Released</title><link rel="alternate" type="text/html" href="http://weblogs.asp.net/darrensim/archive/2008/07/05/composite-application-guidance-cag-for-wpf-aka-prism-released.aspx" /><id>http://weblogs.asp.net/darrensim/archive/2008/07/05/composite-application-guidance-cag-for-wpf-aka-prism-released.aspx</id><published>2008-07-05T07:07:00Z</published><updated>2008-07-05T07:07:00Z</updated><content type="html">&lt;P mce_keep="true"&gt;&lt;SPAN class=Apple-style-span style="WORD-SPACING: 0px; FONT: 12px Arial; TEXT-TRANSFORM: none; COLOR: rgb(0,0,0); TEXT-INDENT: 0px; LETTER-SPACING: normal; BORDER-COLLAPSE: separate; orphans: 2; widows: 2; -webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; -webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0"&gt;&lt;IMG style="WIDTH: 400px; HEIGHT: 303px" height=303 src="http://darrensim.com/photos/blogpics/images/9822/original.aspx" width=400 mce_src="http://darrensim.com/photos/blogpics/images/9822/original.aspx"&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P mce_keep="true"&gt;&lt;SPAN class=Apple-style-span style="WORD-SPACING: 0px; FONT: 12px Arial; TEXT-TRANSFORM: none; COLOR: rgb(0,0,0); TEXT-INDENT: 0px; LETTER-SPACING: normal; BORDER-COLLAPSE: separate; orphans: 2; widows: 2; -webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; -webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0"&gt;Microsoft's P&amp;amp;P team has just release a new Guidance for WPF, &lt;/SPAN&gt;&lt;SPAN class=Apple-style-span style="WORD-SPACING: 0px; FONT: 12px Arial; TEXT-TRANSFORM: none; COLOR: rgb(0,0,0); TEXT-INDENT: 0px; LETTER-SPACING: normal; BORDER-COLLAPSE: separate; orphans: 2; widows: 2; -webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; -webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0"&gt;formerly known as “Prism” and CAG for WPF June 2008 was just released. It may help you adopting WPF and revitalize your experience with WPF.&amp;nbsp; &lt;/SPAN&gt;&lt;/P&gt;
&lt;P mce_keep="true"&gt;&lt;SPAN class=Apple-style-span style="WORD-SPACING: 0px; FONT: 12px Arial; TEXT-TRANSFORM: none; COLOR: rgb(0,0,0); TEXT-INDENT: 0px; LETTER-SPACING: normal; BORDER-COLLAPSE: separate; orphans: 2; widows: 2; -webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; -webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0"&gt;The Composite Application Guidance for WPF is designed to help you more easily build enterprise-level Windows Presentation Foundation (WPF) client applications. This guidance will help you design and build flexible composite WPF client applications—composite applications use loosely coupled, independently evolvable pieces that work together in the overall application. &lt;/SPAN&gt;&lt;/P&gt;
&lt;P mce_keep="true"&gt;&lt;SPAN class=Apple-style-span style="WORD-SPACING: 0px; FONT: 12px Arial; TEXT-TRANSFORM: none; COLOR: rgb(0,0,0); TEXT-INDENT: 0px; LETTER-SPACING: normal; BORDER-COLLAPSE: separate; orphans: 2; widows: 2; -webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; -webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0"&gt;Using the guidance streamlines the WPF team development experience. You can build solutions that take advantage of the full power of WPF and that are highly maintainable, testable, and whose pieces can be developed by separate teams. &lt;/SPAN&gt;&lt;/P&gt;
&lt;P mce_keep="true"&gt;&lt;SPAN class=Apple-style-span style="WORD-SPACING: 0px; FONT: 12px Arial; TEXT-TRANSFORM: none; COLOR: rgb(0,0,0); TEXT-INDENT: 0px; LETTER-SPACING: normal; BORDER-COLLAPSE: separate; orphans: 2; widows: 2; -webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; -webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0"&gt;&lt;STRONG&gt;Composite WPF on Codeplex&lt;/STRONG&gt;: &lt;A href="http://www.codeplex.com/CompositeWPF/"&gt;http://www.codeplex.com/CompositeWPF/&lt;/A&gt; &lt;BR&gt;&lt;/SPAN&gt;&lt;SPAN class=Apple-style-span style="WORD-SPACING: 0px; FONT: 12px Arial; TEXT-TRANSFORM: none; COLOR: rgb(0,0,0); TEXT-INDENT: 0px; LETTER-SPACING: normal; BORDER-COLLAPSE: separate; orphans: 2; widows: 2; -webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; -webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0"&gt;&lt;STRONG&gt;Composite WPF on &lt;/STRONG&gt;&lt;/SPAN&gt;&lt;SPAN class=Apple-style-span style="WORD-SPACING: 0px; FONT: 12px Arial; TEXT-TRANSFORM: none; COLOR: rgb(0,0,0); TEXT-INDENT: 0px; LETTER-SPACING: normal; BORDER-COLLAPSE: separate; orphans: 2; widows: 2; -webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; -webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0"&gt;&lt;STRONG&gt;MSDN&lt;/STRONG&gt;: &lt;A href="http://msdn.microsoft.com/en-us/library/cc707819.aspx"&gt;http://msdn.microsoft.com/en-us/library/cc707819.aspx&lt;/A&gt; &lt;/SPAN&gt;&lt;BR class=Apple-interchange-newline&gt;&lt;/P&gt;&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=6361497" width="1" height="1"&gt;</content><author><name>Darren.Sim</name><uri>http://weblogs.asp.net/members/Darren.Sim.aspx</uri></author><category term="WPF" scheme="http://weblogs.asp.net/darrensim/archive/tags/WPF/default.aspx" /><category term=".NET" scheme="http://weblogs.asp.net/darrensim/archive/tags/.NET/default.aspx" /></entry><entry><title>Creating an Outlook Message File with C#</title><link rel="alternate" type="text/html" href="http://weblogs.asp.net/darrensim/archive/2008/06/29/creating-an-outlook-message-file-with-c.aspx" /><link rel="enclosure" type="application/x-zip-compressed" length="116415" href="http://weblogs.asp.net/darrensim/attachment/6332389.ashx" /><id>http://weblogs.asp.net/darrensim/archive/2008/06/29/creating-an-outlook-message-file-with-c.aspx</id><published>2008-06-28T23:38:00Z</published><updated>2008-06-28T23:38:00Z</updated><content type="html">&lt;P mce_keep="true"&gt;I've been working with a government agency lately, and came to notice that the software system they're using dates back to the stone ages. Many a time, the head of department is required to send an email to other head of departments within the same organization, each with a similar content, yet with attachment of nominal roll of folks under each of the departments (PS: HR Stuff).&lt;/P&gt;
&lt;P mce_keep="true"&gt;On every occasion that I observe, this poor balding guy has to create a template in outlook and copy it 20 times, adding the list of recipients to the individual MSG file and attaching the relevant set of excel/word document file for each of these departments.&lt;/P&gt;
&lt;P mce_keep="true"&gt;Of course, as a software engineer, the first thing on the mind is definitely, "AUTOMATION"!&lt;/P&gt;
&lt;P mce_keep="true"&gt;Microsoft Office Outlook does have an &lt;STRONG&gt;interop dll&lt;/STRONG&gt; which specifically allows for this to be done, easily! Another altanative would definitely be making use of &lt;STRONG&gt;Visual Studio Tools for Office (VSTO)&lt;/STRONG&gt;.&lt;/P&gt;
&lt;P mce_keep="true"&gt;To save you the trouble of looking for this DLL, i've attached a copy to this blogpost.&lt;/P&gt;
&lt;P mce_keep="true"&gt;1. To begin, let's first create a C# Winforms Project in Visual Studio.&lt;/P&gt;
&lt;P mce_keep="true"&gt;2. Next, let's add the reference to the interop DLL (attached on this blog post). You should see something like the following.&lt;/P&gt;
&lt;P mce_keep="true"&gt;&lt;IMG style="WIDTH: 186px; HEIGHT: 163px" height=163 src="http://darrensim.com/photos/blogpics/images/9677/original.aspx" width=186 mce_src="http://darrensim.com/photos/blogpics/images/9677/original.aspx"&gt;&lt;/P&gt;
&lt;P mce_keep="true"&gt;3. For the purpose of this tutorial, we'd create a simple windows form which takes in the &lt;STRONG&gt;mail receipient&lt;/STRONG&gt;, &lt;STRONG&gt;subject&lt;/STRONG&gt;, &lt;STRONG&gt;message&lt;/STRONG&gt; and &lt;STRONG&gt;attachment&lt;/STRONG&gt; fields. Once you're familiar with how the code (which we'd discuss later), you can work more magic around this (e.g. creating automation processes)&lt;/P&gt;
&lt;P mce_keep="true"&gt;&lt;IMG style="WIDTH: 500px; HEIGHT: 368px" height=368 src="http://darrensim.com/photos/blogpics/images/9678/original.aspx" width=500 mce_src="http://darrensim.com/photos/blogpics/images/9678/original.aspx"&gt;&lt;/P&gt;
&lt;P mce_keep="true"&gt;Note: The &lt;STRONG&gt;Importance ComboBox&lt;/STRONG&gt; should have the following values "High","Normal" and 'Low".&lt;/P&gt;
&lt;P mce_keep="true"&gt;4. Next step, is to wire up the code-behind for the &lt;STRONG&gt;Save Button&lt;/STRONG&gt;. It's optional whether you want to register the Outlook Interop in the namespace or not. In this example, I do not so so, thus qualifying the full path in the code (below).&lt;/P&gt;&lt;FONT size=2&gt;
&lt;P&gt;&lt;/FONT&gt;&lt;FONT size=2&gt;&lt;FONT color=#008000 size=2&gt;&lt;FONT color=#008000 size=2&gt;// Creates a new Outlook Application Instance&lt;BR&gt;&lt;FONT color=#000000&gt;Outlook.&lt;/FONT&gt;&lt;FONT color=#2b91af size=2&gt;&lt;FONT color=#2b91af size=2&gt;Application&lt;/FONT&gt;&lt;/FONT&gt;&lt;FONT color=#000000 size=2&gt; objOutlook = &lt;/FONT&gt;&lt;FONT color=#0000ff size=2&gt;&lt;FONT color=#0000ff size=2&gt;new&lt;/FONT&gt;&lt;/FONT&gt;&lt;FONT color=#000000 size=2&gt; Outlook.&lt;/FONT&gt;&lt;FONT color=#2b91af size=2&gt;&lt;FONT color=#2b91af size=2&gt;Application&lt;/FONT&gt;&lt;/FONT&gt;&lt;FONT color=#000000 size=2&gt;(); &lt;/FONT&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT size=2&gt;&lt;FONT color=#008000 size=2&gt;&lt;FONT color=#008000 size=2&gt;// Creating a new Outlook Message from the Outlook Application Instance&lt;/FONT&gt;&lt;/FONT&gt;&lt;BR&gt;Outlook.&lt;/FONT&gt;&lt;FONT color=#2b91af size=2&gt;&lt;FONT color=#2b91af size=2&gt;MailItem&lt;/FONT&gt;&lt;/FONT&gt;&lt;FONT size=2&gt; mic = (Outlook.&lt;/FONT&gt;&lt;FONT color=#2b91af size=2&gt;&lt;FONT color=#2b91af size=2&gt;MailItem&lt;/FONT&gt;&lt;/FONT&gt;&lt;FONT size=2&gt;)(objOutlook.CreateItem(Outlook.&lt;/FONT&gt;&lt;FONT color=#2b91af size=2&gt;&lt;FONT color=#2b91af size=2&gt;OlItemType&lt;/FONT&gt;&lt;/FONT&gt;&lt;FONT size=2&gt;.olMailItem)); &lt;/FONT&gt;&lt;/P&gt;&lt;FONT color=#008000 size=2&gt;&lt;FONT color=#008000 size=2&gt;// Assigns the "TO", "CC" and "BCC" Fields&lt;BR&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;FONT size=2&gt;&lt;FONT size=2&gt;mic.To = toTextBox.Text;&lt;BR&gt;mic.CC = ccTextBox.Text;&lt;BR&gt;mic.BCC = bccTextBox.Text;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;FONT size=2&gt;&lt;FONT size=2&gt;&lt;FONT color=#008000 size=2&gt;&lt;FONT color=#008000 size=2&gt; 
&lt;P&gt;// Assigns the Subject Field&lt;BR&gt;&lt;/FONT&gt;&lt;/FONT&gt;mic.Subject = subjectTextBox.Text;&lt;/P&gt;&lt;FONT color=#0000ff size=2&gt;&lt;FONT color=#0000ff size=2&gt;&lt;FONT color=#008000 size=2&gt;&lt;FONT color=#008000 size=2&gt;// Switch the Importance ComboBox to identify the Mail Message Importance Level&lt;BR&gt;&lt;/FONT&gt;&lt;/FONT&gt;switch&lt;/FONT&gt;&lt;/FONT&gt;&lt;FONT size=2&gt; (importanceComboBox.SelectedItem.ToString())&lt;BR&gt;{&lt;BR&gt;&lt;/FONT&gt;&lt;FONT color=#0000ff size=2&gt;&lt;FONT color=#0000ff size=2&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; case&lt;/FONT&gt;&lt;/FONT&gt;&lt;FONT size=2&gt; &lt;/FONT&gt;&lt;FONT color=#a31515 size=2&gt;&lt;FONT color=#a31515 size=2&gt;"High"&lt;/FONT&gt;&lt;/FONT&gt;&lt;FONT size=2&gt;:&lt;BR&gt;&lt;FONT color=#0000ff&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/FONT&gt;mic.Importance = Outlook.&lt;/FONT&gt;&lt;FONT color=#2b91af size=2&gt;&lt;FONT color=#2b91af size=2&gt;OlImportance&lt;/FONT&gt;&lt;/FONT&gt;&lt;FONT size=2&gt;.olImportanceHigh;&lt;BR&gt;&lt;/FONT&gt;&lt;FONT color=#0000ff size=2&gt;&lt;FONT color=#0000ff size=2&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; break&lt;/FONT&gt;&lt;/FONT&gt;&lt;FONT size=2&gt;;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;FONT size=2&gt; &lt;/FONT&gt;&lt;FONT color=#0000ff size=2&gt;&lt;FONT color=#0000ff size=2&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; case&lt;/FONT&gt;&lt;/FONT&gt;&lt;FONT size=2&gt; &lt;/FONT&gt;&lt;FONT color=#a31515 size=2&gt;&lt;FONT color=#a31515 size=2&gt;"Normal"&lt;/FONT&gt;&lt;/FONT&gt;&lt;FONT size=2&gt;:&lt;BR&gt;&lt;FONT color=#0000ff&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/FONT&gt;mic.Importance = Outlook.&lt;/FONT&gt;&lt;FONT color=#2b91af size=2&gt;&lt;FONT color=#2b91af size=2&gt;OlImportance&lt;/FONT&gt;&lt;/FONT&gt;&lt;FONT size=2&gt;.olImportanceNormal;&lt;BR&gt;&lt;/FONT&gt;&lt;FONT color=#0000ff size=2&gt;&lt;FONT color=#0000ff size=2&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; break&lt;/FONT&gt;&lt;/FONT&gt;&lt;FONT size=2&gt;;&lt;/FONT&gt;&lt;/FONT&gt;&lt;FONT size=2&gt; 
&lt;P&gt;&lt;/FONT&gt;&lt;FONT color=#0000ff size=2&gt;&lt;FONT color=#0000ff size=2&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; case&lt;/FONT&gt;&lt;/FONT&gt;&lt;FONT size=2&gt; &lt;/FONT&gt;&lt;FONT color=#a31515 size=2&gt;&lt;FONT color=#a31515 size=2&gt;"Low"&lt;/FONT&gt;&lt;/FONT&gt;&lt;FONT size=2&gt;:&lt;BR&gt;&lt;FONT color=#0000ff&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/FONT&gt;mic.Importance = Outlook.&lt;/FONT&gt;&lt;FONT color=#2b91af size=2&gt;&lt;FONT color=#2b91af size=2&gt;OlImportance&lt;/FONT&gt;&lt;/FONT&gt;&lt;FONT size=2&gt;.olImportanceLow;&lt;BR&gt;&lt;/FONT&gt;&lt;FONT color=#0000ff size=2&gt;&lt;FONT color=#0000ff size=2&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; break&lt;/FONT&gt;&lt;/FONT&gt;&lt;FONT size=2&gt;;&lt;BR&gt;}&lt;/FONT&gt;&lt;/P&gt;&lt;FONT size=2&gt;&lt;FONT size=2&gt;&lt;FONT color=#008000 size=2&gt;&lt;FONT color=#008000 size=2&gt;
&lt;P&gt;// Define the Mail Message Body. In this example, you can add in HTML content to the mail message body&lt;BR&gt;&lt;/FONT&gt;&lt;/FONT&gt;mic.HTMLBody = messageTextBox.Text;&lt;/P&gt;&lt;FONT color=#008000 size=2&gt;&lt;FONT color=#008000 size=2&gt;
&lt;P&gt;// Adds Attachment to the Mail Message. &lt;BR&gt;// Note: You could add more than one attachment to the mail message. &lt;BR&gt;// All you need to do is to declare this relative to the number of attachments you have.&lt;BR&gt;&lt;/FONT&gt;&lt;/FONT&gt;mic.Attachments.Add(attachmentOneTextBox.Text,Outlook.&lt;/FONT&gt;&lt;FONT color=#2b91af size=2&gt;&lt;FONT color=#2b91af size=2&gt;OlAttachmentType&lt;/FONT&gt;&lt;/FONT&gt;&lt;FONT size=2&gt;.olByValue,1,&lt;/FONT&gt;&lt;FONT color=#a31515 size=2&gt;&lt;FONT color=#a31515 size=2&gt;"Attachment Name"&lt;/FONT&gt;&lt;/FONT&gt;&lt;FONT size=2&gt;);&lt;/FONT&gt;&lt;/P&gt;&lt;FONT size=2&gt;&lt;FONT size=2&gt;&lt;FONT color=#008000 size=2&gt;&lt;FONT color=#008000 size=2&gt;
&lt;P&gt;// Save the message to C:\demo.msg. Alternatively you can create a SaveFileDialog to &lt;BR&gt;// allow users to choose where to save the file&lt;BR&gt;&lt;/FONT&gt;&lt;/FONT&gt;mic.SaveAs(&lt;/FONT&gt;&lt;FONT color=#a31515 size=2&gt;&lt;FONT color=#a31515 size=2&gt;@"C:\demo.msg"&lt;/FONT&gt;&lt;/FONT&gt;&lt;FONT size=2&gt;, Outlook.&lt;/FONT&gt;&lt;FONT color=#2b91af size=2&gt;&lt;FONT color=#2b91af size=2&gt;OlSaveAsType&lt;/FONT&gt;&lt;/FONT&gt;&lt;FONT size=2&gt;.olMSG);&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT size=2&gt;Easy isn't it? Besides creating mail messages, you can also create other outlook items such as task, calendar objects and more. More to come in the future posts. Do let me know your comments/views on this post.&lt;/FONT&gt;&lt;/P&gt;
&lt;P mce_keep="true"&gt;&amp;nbsp;&lt;/P&gt;&lt;FONT size=2&gt;
&lt;P mce_keep="true"&gt;&lt;STRONG&gt;Attachments&lt;/STRONG&gt;: &lt;/P&gt;
&lt;P mce_keep="true"&gt;&lt;A href="http://darrensim.com/files/folders/presentations/entry9679.aspx"&gt;&lt;IMG src="http://darrensim.com/utility/filethumbnails/pdf.gif" align=absMiddle border=0&gt;&lt;/A&gt;&amp;nbsp;Tutorial in PDF Format (&lt;A href="http://darrensim.com/files/folders/presentations/entry9679.aspx"&gt;http://darrensim.com/files/folders/presentations/entry9679.aspx&lt;/A&gt;)&lt;/P&gt;
&lt;P mce_keep="true"&gt;&lt;A href="http://darrensim.com/files/folders/presentations/entry9680.aspx"&gt;&lt;IMG src="http://darrensim.com/utility/filethumbnails/zip.gif" align=absMiddle border=0&gt;&lt;/A&gt;&amp;nbsp;Interop.Outlook (&lt;A href="http://darrensim.com/files/folders/presentations/entry9680.aspx"&gt;http://darrensim.com/files/folders/presentations/entry9680.aspx&lt;/A&gt;)&lt;/P&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=6332389" width="1" height="1"&gt;</content><author><name>Darren.Sim</name><uri>http://weblogs.asp.net/members/Darren.Sim.aspx</uri></author><category term="C#" scheme="http://weblogs.asp.net/darrensim/archive/tags/C_2300_/default.aspx" /><category term="Outlook" scheme="http://weblogs.asp.net/darrensim/archive/tags/Outlook/default.aspx" /></entry></feed>