<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="http://devpinoy.org/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>Driving .NET</title><link>http://devpinoy.org/blogs/smash/default.aspx</link><description /><dc:language>en</dc:language><generator>CommunityServer 2008.5 SP1 (Build: 31106.3070)</generator><item><title>Ruby on the rise</title><link>http://devpinoy.org/blogs/smash/archive/2007/06/23/ruby-on-the-rise.aspx</link><pubDate>Sat, 23 Jun 2007 02:41:00 GMT</pubDate><guid isPermaLink="false">99090821-4da1-4a75-98c2-a35884625ff7:10882</guid><dc:creator>smash</dc:creator><slash:comments>3</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://devpinoy.org/blogs/smash/rsscomments.aspx?PostID=10882</wfw:commentRss><comments>http://devpinoy.org/blogs/smash/archive/2007/06/23/ruby-on-the-rise.aspx#comments</comments><description>&lt;p&gt;Ruby the programming language has been around for quite a while, though quite popular in Japan, it never made any inroads into the mainstream of computing.&amp;nbsp; Only recently it made quite a splash&amp;nbsp;with the emergence of Ruby on Rails (RoR) as an alternative web application framework.&amp;nbsp; Yet it still remains stuck in the peripherals, with Java and .NET dominating the corporate computing space.&amp;nbsp;&amp;nbsp;A sad fate&amp;nbsp;indeed for probably the best dynamic object oriented language in geek lore.&lt;/p&gt;
&lt;p&gt;But Ruby&amp;#39;s fate is about to take a detour, with the upcoming Ruby IDE from CodeGear (the company formerly known as Borland, then Inprise, then Borland again!) and suprise surprise - Netbeans 6.0.&amp;nbsp; The latter has a preview download while the former is still vaporware.&amp;nbsp; &lt;/p&gt;
&lt;p&gt;So will Ruby finally become mainstream and pose a threat to&amp;nbsp;java and c#?&amp;nbsp;&amp;nbsp;&amp;nbsp; I will probably have an answer to that after I have installed Netbeans 6.0.&amp;nbsp;&amp;nbsp;The problem is, I might enjoy it a lot and decide to never look back.&amp;nbsp; &lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://devpinoy.org/aggbug.aspx?PostID=10882" width="1" height="1"&gt;</description></item><item><title>Painless Ajax for ASP.NET with Gaia Ajax Widgets</title><link>http://devpinoy.org/blogs/smash/archive/2007/06/22/painless-ajax-for-asp-net-with-gaia-ajax-widgets.aspx</link><pubDate>Fri, 22 Jun 2007 05:10:00 GMT</pubDate><guid isPermaLink="false">99090821-4da1-4a75-98c2-a35884625ff7:10862</guid><dc:creator>smash</dc:creator><slash:comments>0</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://devpinoy.org/blogs/smash/rsscomments.aspx?PostID=10862</wfw:commentRss><comments>http://devpinoy.org/blogs/smash/archive/2007/06/22/painless-ajax-for-asp-net-with-gaia-ajax-widgets.aspx#comments</comments><description>&lt;p&gt;I found this library while researching the web for an alternative AJAX solution for ASP.NET sans Javascript.&amp;nbsp; The thing is, if you know how to use those built in WebControls, then you already know how to use Gaia since most of its widgets mirror those found in ASP.NET.&amp;nbsp; The window and autocompleter controls are very impressive.&amp;nbsp; &lt;/p&gt;
&lt;p&gt;&amp;nbsp;Gaia makes the Ajax toolkit from Microsoft&amp;nbsp;look ummm ... outdated.&amp;nbsp; See for yourself&amp;nbsp;&lt;a class="" href="http://ajaxwidgets.com/screenshots.aa"&gt;here&lt;/a&gt;.&amp;nbsp;&amp;nbsp; &lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://devpinoy.org/aggbug.aspx?PostID=10862" width="1" height="1"&gt;</description></item><item><title>a parser tale</title><link>http://devpinoy.org/blogs/smash/archive/2007/05/17/a-parser-tale.aspx</link><pubDate>Thu, 17 May 2007 00:59:00 GMT</pubDate><guid isPermaLink="false">99090821-4da1-4a75-98c2-a35884625ff7:9651</guid><dc:creator>smash</dc:creator><slash:comments>2</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://devpinoy.org/blogs/smash/rsscomments.aspx?PostID=9651</wfw:commentRss><comments>http://devpinoy.org/blogs/smash/archive/2007/05/17/a-parser-tale.aspx#comments</comments><description>&lt;p&gt;I still can&amp;#39;t believe that I&amp;#39;ll ever be involved in a project that entails writing a parser.&amp;nbsp; My first crack at writing one was for my college thesis. If I remember correctly, it was&amp;nbsp;part of a&amp;nbsp;C language&amp;nbsp;interpreter which the panel of judges deemed useless since compilers for C were already available.&amp;nbsp;&amp;nbsp;It was so painful to hear that comment since the interpreter did work.&amp;nbsp;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;Well I guess, the work I put into that project has finally paid off since our HL7 parser is well on its way, after only less than 24 hours of coding and testing.&amp;nbsp; I was really feeling nostalgic while sketching the state transition diagrams on blank sheets of paper.&amp;nbsp; Ofcourse having those drawings transferred to Visio was really cool.&amp;nbsp; &lt;/p&gt;
&lt;p&gt;NUnit is really one heck of a tool.&amp;nbsp; Without it, I could be mired in creating test projects for all the possible use cases for days.&amp;nbsp; Contrast that to writing your testing code side by side with your application code.&amp;nbsp; &lt;/p&gt;
&lt;p&gt;Alan Cooper once said, that programming is like digging the Panama Canal with a spoon, and with .NET programming is still hard but it&amp;#39;s like digging the Panama Canal with a backhoe.&amp;nbsp; I guess with NUnit you can say&amp;nbsp;that programming is still hard but it&amp;#39;s like digging the Panama Canal with two backhoes.&amp;nbsp; &lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://devpinoy.org/aggbug.aspx?PostID=9651" width="1" height="1"&gt;</description></item><item><title>ClassicReport does XPS</title><link>http://devpinoy.org/blogs/smash/archive/2007/05/11/classicreport-does-xps.aspx</link><pubDate>Thu, 10 May 2007 23:46:00 GMT</pubDate><guid isPermaLink="false">99090821-4da1-4a75-98c2-a35884625ff7:9569</guid><dc:creator>smash</dc:creator><slash:comments>0</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://devpinoy.org/blogs/smash/rsscomments.aspx?PostID=9569</wfw:commentRss><comments>http://devpinoy.org/blogs/smash/archive/2007/05/11/classicreport-does-xps.aspx#comments</comments><description>You now can export your ClassicReport documents to Xps as shown below.&amp;nbsp; I&amp;#39;m also experimenting with this auto-zooming report viewer.&amp;nbsp; Check them out.&amp;nbsp; &lt;br /&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;a href="http://www.flickr.com/photos/jasonjimenez/493181861/" title="Photo Sharing"&gt;&lt;img src="http://farm1.static.flickr.com/198/493181861_19b8683a4d.jpg" alt="wpf viewers" height="362" width="500" /&gt;&lt;/a&gt;
&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://devpinoy.org/aggbug.aspx?PostID=9569" width="1" height="1"&gt;</description><enclosure url="http://devpinoy.org/cfs-file.ashx/__key/CommunityServer.Components.PostAttachments/00.00.00.95.69/ClassicReportSample.zip" length="3042120" type="application/octet-stream" /><category domain="http://devpinoy.org/blogs/smash/archive/tags/.NET/default.aspx">.NET</category><category domain="http://devpinoy.org/blogs/smash/archive/tags/ClassicReports/default.aspx">ClassicReports</category></item><item><title>using Backbase forms in ASP.NET</title><link>http://devpinoy.org/blogs/smash/archive/2007/04/16/using-backbase-forms-in-asp-net.aspx</link><pubDate>Mon, 16 Apr 2007 03:23:00 GMT</pubDate><guid isPermaLink="false">99090821-4da1-4a75-98c2-a35884625ff7:8887</guid><dc:creator>smash</dc:creator><slash:comments>7</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://devpinoy.org/blogs/smash/rsscomments.aspx?PostID=8887</wfw:commentRss><comments>http://devpinoy.org/blogs/smash/archive/2007/04/16/using-backbase-forms-in-asp-net.aspx#comments</comments><description>&lt;p&gt;I finally had the opportunity to take the &lt;a href="http://backbase.com"&gt;Backbase &lt;/a&gt;Community Edition&amp;nbsp; for a spin - and boy it rocks!&amp;nbsp; After a couple of hours working with this I finally figured out how to make this AJAX framework to work in an ASP.NET web project.&amp;nbsp; One of the usual stuff that we do in web applications is form submission.&amp;nbsp; So it wasnt a surpise to find out that Backbase has its own way of handling forms, which is really incompatible with ASP.NET.&amp;nbsp;Backbase is pure HTML and that could be a curse or a blessing.&amp;nbsp; To test this facility, I created a new HTML form and wrote the following in the body:&lt;/p&gt;
&lt;div&gt;&amp;lt;xmp b:backbase="true"&amp;gt;&lt;/div&gt;
&lt;div&gt;&amp;lt;form name="form1" &lt;/div&gt;
&lt;div&gt;&amp;nbsp; method="post" &lt;/div&gt;
&lt;div&gt;&amp;nbsp; action="reponse.ashx" &lt;/div&gt;
&lt;div&gt;&amp;nbsp; b:destination="id('destination')"&lt;/div&gt;
&lt;div&gt;&amp;nbsp; b:mode="replace"&amp;gt;&lt;/div&gt;
&lt;div&gt;&amp;nbsp; User:&amp;lt;input type="text" name="user" /&amp;gt;&lt;/div&gt;
&lt;div&gt;&amp;nbsp; &amp;lt;b:button b:action="submit" b:target="ancestor::form[1]"&amp;gt;Send&amp;lt;/b:button&amp;gt;&lt;/div&gt;
&lt;div&gt;&amp;lt;/form&amp;gt;&lt;/div&gt;
&lt;div&gt;&amp;lt;div id="destination" /&amp;gt;&lt;/div&gt;
&lt;div&gt;&amp;lt;/xmp&amp;gt;&lt;/div&gt;
&lt;p&gt;The object of this exercise was simple. Enter the name of the user on the textbox and upon clicking the submit button, the name of the user should appear&amp;nbsp;in place of &amp;lt;div id="destination"/&amp;gt; tag.&amp;nbsp; Did it work? Yes it did, even before I could bat an eyelash.&amp;nbsp; &lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://devpinoy.org/aggbug.aspx?PostID=8887" width="1" height="1"&gt;</description><category domain="http://devpinoy.org/blogs/smash/archive/tags/ASP.NET/default.aspx">ASP.NET</category><category domain="http://devpinoy.org/blogs/smash/archive/tags/AJAX/default.aspx">AJAX</category><category domain="http://devpinoy.org/blogs/smash/archive/tags/Backbase/default.aspx">Backbase</category></item><item><title>notes on the ClassicReport Control </title><link>http://devpinoy.org/blogs/smash/archive/2007/04/07/notes-on-the-classicreport-control.aspx</link><pubDate>Sat, 07 Apr 2007 11:36:00 GMT</pubDate><guid isPermaLink="false">99090821-4da1-4a75-98c2-a35884625ff7:8826</guid><dc:creator>smash</dc:creator><slash:comments>0</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://devpinoy.org/blogs/smash/rsscomments.aspx?PostID=8826</wfw:commentRss><comments>http://devpinoy.org/blogs/smash/archive/2007/04/07/notes-on-the-classicreport-control.aspx#comments</comments><description>&lt;p&gt;the next update of the ClassicReports for .NET&amp;nbsp; will include a new databound ClassicReport control so you wont have to write those&amp;nbsp;event handlers unless really necessary. &amp;nbsp; you&amp;nbsp;will be able to edit the report at design time by clicking the&amp;nbsp;small button that appears when the Template property has focus on the PropertyGrid.&amp;nbsp; implementing the UITypeEditor was as simple as dropping the ReportDesigner in a form.&amp;nbsp; &lt;/p&gt;
&lt;p&gt;i was flipflopping on whether to use BindingSource or object as the type for the DataSource property.&amp;nbsp; i finally chose the latter which seems to be the norm.&amp;nbsp; the UITypeEditor for the DataSource property will have to wait a little longer, maybe a week or so depending on my free time ofcourse.&amp;nbsp; &lt;/p&gt;
&lt;p&gt;i also decided to make public the Document property which you will now use to pass to the Preview control or&amp;nbsp; PrinterService.&amp;nbsp; (i will also be making available&amp;nbsp;a PDFService and&amp;nbsp;XPSService soon)&amp;nbsp;&amp;nbsp;the Document object contains the collection of Pages which the ReportComposer populates.&amp;nbsp; &lt;/p&gt;
&lt;p&gt;Here&amp;#39;s how to use the new control programmatically. &lt;/p&gt;&lt;pre&gt;ClassicReport report = new ClassicReport();
report.Template = GetTemplate();  
report.DataSource = GetData();
report.Execute();
PrinterService printer = new PrinterService(report.Document);
printer.PrintAll(); 
&lt;/pre&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://devpinoy.org/aggbug.aspx?PostID=8826" width="1" height="1"&gt;</description><category domain="http://devpinoy.org/blogs/smash/archive/tags/.NET/default.aspx">.NET</category><category domain="http://devpinoy.org/blogs/smash/archive/tags/ClassicReports/default.aspx">ClassicReports</category></item><item><title>Forcing a visual tree repaint in WPF</title><link>http://devpinoy.org/blogs/smash/archive/2006/10/28/Forcing-a-visual-tree-repaint-in-WPF.aspx</link><pubDate>Sat, 28 Oct 2006 06:42:24 GMT</pubDate><guid isPermaLink="false">99090821-4da1-4a75-98c2-a35884625ff7:5959</guid><dc:creator>smash</dc:creator><slash:comments>0</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://devpinoy.org/blogs/smash/rsscomments.aspx?PostID=5959</wfw:commentRss><comments>http://devpinoy.org/blogs/smash/archive/2006/10/28/Forcing-a-visual-tree-repaint-in-WPF.aspx#comments</comments><description>&lt;p&gt;So what does InvalidateVisual do? The SDK documentation&amp;nbsp;says&amp;nbsp;it "&lt;em&gt;&lt;u&gt;invalidates the rendering of the element, and forces a complete new layout pass. OnRender is called after the layout cycle is completed"&lt;/u&gt;&lt;/em&gt;.&amp;nbsp; Just what I needed when it was time to implement&amp;nbsp;scrolling&amp;nbsp;for a custom control shown below - or so I thought.&lt;/p&gt; &lt;p&gt;&lt;a title="populated bands unscrolled" href="http://www.flickr.com/photos/73686286@N00/281136977/"&gt;&lt;img alt="populated bands unscrolled" hspace="0" src="http://static.flickr.com/109/281136977_1a3ac6af3a.jpg" border="0"&gt;&lt;/a&gt;&lt;/p&gt; &lt;p&gt;The custom horizontal scrollbar at the bottom of the control is bound to an ICommand whose implementation is shown below:&lt;/p&gt;&lt;pre&gt;	
class ScrollCommand : BaseCommand
{
    public ScrollCommand(Controller controller)
	: base(controller)
    {
    }

    public override void Execute(object parameter)
    {
	double value = (double)parameter;
	controller.horScroll = value;
	controller.designer.InvalidateVisual();
    }
}
&lt;/pre&gt;
&lt;p&gt;The Execute method will force the UIElements Field1, Field2 and Field3&amp;nbsp;to be repositioned in their respective canvas container relative to the value of the scrollbar by calling the host control's InvalidateVisual method.&amp;nbsp; This provides the illusion of scrolling. It was a dud.&lt;/p&gt;
&lt;p&gt;I was beginning to doubt this whole WPF Binding thing when I chanced upon the Measure method.&amp;nbsp;The SDK describes this as&amp;nbsp;"&lt;em&gt;&lt;u&gt;Updates the DesiredSize of a UIElement. Parent elements call this method from their own MeasureCore implementations to form a recursive layout update. Calling this method constitutes the first pass of a layout update in the layout engine&lt;/u&gt;&lt;/em&gt;".&amp;nbsp; It looked very promising, so i replaced the call to InvalidateVisual with Measure as show below:&lt;/p&gt;
&lt;pre&gt;	
    public override void Execute(object parameter)
    {
	double value = (double)parameter;
	controller.horScroll = value;
	controller.designer.Measure(new Size());
    }
&lt;/pre&gt;
&lt;p&gt;Needless to say it worked!&lt;/p&gt;&lt;a title="populated bands scrolled" href="http://www.flickr.com/photos/73686286@N00/281136963/"&gt;&lt;img alt="populated bands scrolled" hspace="0" src="http://static.flickr.com/119/281136963_88c0ce185e.jpg" border="0"&gt;&lt;/a&gt;&lt;img src="http://devpinoy.org/aggbug.aspx?PostID=5959" width="1" height="1"&gt;</description><category domain="http://devpinoy.org/blogs/smash/archive/tags/c_2300_/default.aspx">c#</category><category domain="http://devpinoy.org/blogs/smash/archive/tags/.NET/default.aspx">.NET</category><category domain="http://devpinoy.org/blogs/smash/archive/tags/WPF/default.aspx">WPF</category></item><item><title>building a full trust XBAP app</title><link>http://devpinoy.org/blogs/smash/archive/2006/10/13/building-a-full-trust-XBAP-app.aspx</link><pubDate>Thu, 12 Oct 2006 20:22:44 GMT</pubDate><guid isPermaLink="false">99090821-4da1-4a75-98c2-a35884625ff7:5571</guid><dc:creator>smash</dc:creator><slash:comments>0</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://devpinoy.org/blogs/smash/rsscomments.aspx?PostID=5571</wfw:commentRss><comments>http://devpinoy.org/blogs/smash/archive/2006/10/13/building-a-full-trust-XBAP-app.aspx#comments</comments><description>&lt;p&gt;After&amp;nbsp;reading this &lt;a href="http://blogs.msdn.com/karstenj/archive/2005/11/29/498061.aspx"&gt;post&lt;/a&gt;&amp;nbsp;by Karsten, I created a WPF XBAP project that displays the ClassicReports designer on a Frame as shown below.&lt;/p&gt;&lt;pre class="csharpcode"&gt;&lt;span class="kwrd"&gt;&amp;lt;&lt;/span&gt;&lt;span class="html"&gt;Page&lt;/span&gt; &lt;span class="attr"&gt;x:Class&lt;/span&gt;&lt;span class="kwrd"&gt;=&amp;quot;IApp.Page3&amp;quot;&lt;/span&gt;
    &lt;span class="attr"&gt;xmlns&lt;/span&gt;&lt;span class="kwrd"&gt;=&amp;quot;http://schemas.microsoft.com/winfx/2006/xaml/presentation&amp;quot;&lt;/span&gt;
    &lt;span class="attr"&gt;xmlns:x&lt;/span&gt;&lt;span class="kwrd"&gt;=&amp;quot;http://schemas.microsoft.com/winfx/2006/xaml&amp;quot;&lt;/span&gt;
    &lt;span class="attr"&gt;Title&lt;/span&gt;&lt;span class="kwrd"&gt;=&amp;quot;Page3&amp;quot;&lt;/span&gt;
    &lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;
    &lt;span class="kwrd"&gt;&amp;lt;&lt;/span&gt;&lt;span class="html"&gt;DockPanel&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;
        &lt;span class="kwrd"&gt;&amp;lt;&lt;/span&gt;&lt;span class="html"&gt;ToolBarTray&lt;/span&gt; &lt;span class="attr"&gt;DockPanel&lt;/span&gt;.&lt;span class="attr"&gt;Dock&lt;/span&gt;&lt;span class="kwrd"&gt;=&amp;quot;Top&amp;quot;&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;
            &lt;span class="kwrd"&gt;&amp;lt;&lt;/span&gt;&lt;span class="html"&gt;ToolBar&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;
                &lt;span class="kwrd"&gt;&amp;lt;&lt;/span&gt;&lt;span class="html"&gt;Button&lt;/span&gt; &lt;span class="attr"&gt;Name&lt;/span&gt;&lt;span class="kwrd"&gt;=&amp;quot;newButton&amp;quot;&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;
                    &lt;span class="kwrd"&gt;&amp;lt;&lt;/span&gt;&lt;span class="html"&gt;Image&lt;/span&gt; &lt;span class="attr"&gt;Source&lt;/span&gt;&lt;span class="kwrd"&gt;=&amp;quot;images\new.png&amp;quot;&lt;/span&gt; &lt;span class="kwrd"&gt;/&amp;gt;&lt;/span&gt;
                &lt;span class="kwrd"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="html"&gt;Button&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;
                &lt;span class="kwrd"&gt;&amp;lt;&lt;/span&gt;&lt;span class="html"&gt;Button&lt;/span&gt; &lt;span class="attr"&gt;Name&lt;/span&gt;&lt;span class="kwrd"&gt;=&amp;quot;openButton&amp;quot;&lt;/span&gt; &lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;
                    &lt;span class="kwrd"&gt;&amp;lt;&lt;/span&gt;&lt;span class="html"&gt;Image&lt;/span&gt; &lt;span class="attr"&gt;Source&lt;/span&gt;&lt;span class="kwrd"&gt;=&amp;quot;images\open.png&amp;quot;&lt;/span&gt; &lt;span class="kwrd"&gt;/&amp;gt;&lt;/span&gt;
                &lt;span class="kwrd"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="html"&gt;Button&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;
                &lt;span class="kwrd"&gt;&amp;lt;&lt;/span&gt;&lt;span class="html"&gt;Button&lt;/span&gt;  &lt;span class="attr"&gt;Name&lt;/span&gt;&lt;span class="kwrd"&gt;=&amp;quot;saveButton&amp;quot;&lt;/span&gt; &lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;
                    &lt;span class="kwrd"&gt;&amp;lt;&lt;/span&gt;&lt;span class="html"&gt;Image&lt;/span&gt; &lt;span class="attr"&gt;Source&lt;/span&gt;&lt;span class="kwrd"&gt;=&amp;quot;images\save.png&amp;quot;&lt;/span&gt; &lt;span class="kwrd"&gt;/&amp;gt;&lt;/span&gt;
                &lt;span class="kwrd"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="html"&gt;Button&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;            
            &lt;span class="kwrd"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="html"&gt;ToolBar&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;
        &lt;span class="kwrd"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="html"&gt;ToolBarTray&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;
        &lt;span class="kwrd"&gt;&amp;lt;&lt;/span&gt;&lt;span class="html"&gt;Frame&lt;/span&gt; &lt;span class="attr"&gt;Name&lt;/span&gt;&lt;span class="kwrd"&gt;=&amp;quot;frame1&amp;quot;&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&amp;lt;/&lt;/span&gt;&lt;span class="html"&gt;Frame&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;
    &lt;span class="kwrd"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="html"&gt;DockPanel&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;
&lt;span class="kwrd"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="html"&gt;Page&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;
&lt;/pre&gt;
&lt;p&gt;Below is the&amp;nbsp;c# code behind for the XAML above. Notice that the designer control must first be hosted in a WindowsFormsHost before&amp;nbsp;it can be displayed in WPF.&amp;nbsp; &lt;/p&gt;&lt;pre&gt;namespace IApp
{
    public partial class Page3 : System.Windows.Controls.Page
    {
        JDJ.ClassicReport.ReportDesigner.ReportDesigner designer;

        public Page3()
        {
            InitializeComponent();
            WindowsFormsHost host = new WindowsFormsHost();
            designer = new JDJ.ClassicReport.ReportDesigner.ReportDesigner();
            host.Child = designer;
            frame1.Content = host;
            openButton.Click += new RoutedEventHandler(openButton_Click);
            saveButton.Click += new RoutedEventHandler(saveButton_Click);
            newButton.Click += new RoutedEventHandler(newButton_Click);
        }

        void newButton_Click(object sender, RoutedEventArgs e)
        {
            designer.NewReport();
        }

        void saveButton_Click(object sender, RoutedEventArgs e)
        {
            designer.Save();
        }

        void openButton_Click(object sender, RoutedEventArgs e)
        {
            designer.OpenReport();
        }

    }
}&lt;/pre&gt;
&lt;p&gt;This is how the above page looks like. Notice the address I used in runnning the XBAP application. That&amp;#39;s my actual IP address as of this writing.&lt;/p&gt;&lt;a title="XBAP ClassicReports Designer" href="http://www.flickr.com/photos/73686286@N00/268104211/"&gt;&lt;img alt="XBAP ClassicReports Designer" hspace="0" src="http://static.flickr.com/88/268104211_4838692ca4.jpg" border="0" /&gt;&lt;/a&gt; 
&lt;p&gt;When I clicked on the Open button the dialog box appears.&lt;/p&gt;&lt;a title="XBAP ClassicReports Designer Open File Dialog" href="http://www.flickr.com/photos/73686286@N00/268104126/"&gt;&lt;img alt="XBAP ClassicReports Designer Open File Dialog" hspace="0" src="http://static.flickr.com/85/268104126_f5b7ff1600.jpg" border="0" /&gt;&lt;/a&gt; 
&lt;p&gt;So after selecting the Sample Report File, the designer then displays the report layout on the design surface. Now I can modify the report to my heart&amp;#39;s content.&lt;/p&gt;&lt;a title="XBAP ClassicReports Designer with Sample Report" href="http://www.flickr.com/photos/73686286@N00/268104187/"&gt;&lt;img alt="XBAP ClassicReports Designer with Sample Report" hspace="0" src="http://static.flickr.com/82/268104187_f6abeca9e3.jpg" border="0" /&gt;&lt;/a&gt; 
&lt;p&gt;I almost forgot that I am actually running this rich client application inside a browser!&amp;nbsp; &lt;/p&gt;&lt;img src="http://devpinoy.org/aggbug.aspx?PostID=5571" width="1" height="1"&gt;</description><category domain="http://devpinoy.org/blogs/smash/archive/tags/c_2300_/default.aspx">c#</category><category domain="http://devpinoy.org/blogs/smash/archive/tags/.NET/default.aspx">.NET</category><category domain="http://devpinoy.org/blogs/smash/archive/tags/WPF/default.aspx">WPF</category><category domain="http://devpinoy.org/blogs/smash/archive/tags/XAML/default.aspx">XAML</category><category domain="http://devpinoy.org/blogs/smash/archive/tags/XBAP/default.aspx">XBAP</category></item><item><title>Implementing the ListCollectionView</title><link>http://devpinoy.org/blogs/smash/archive/2006/10/06/Implementing-the-ListCollectionView.aspx</link><pubDate>Fri, 06 Oct 2006 17:57:48 GMT</pubDate><guid isPermaLink="false">99090821-4da1-4a75-98c2-a35884625ff7:5492</guid><dc:creator>smash</dc:creator><slash:comments>0</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://devpinoy.org/blogs/smash/rsscomments.aspx?PostID=5492</wfw:commentRss><comments>http://devpinoy.org/blogs/smash/archive/2006/10/06/Implementing-the-ListCollectionView.aspx#comments</comments><description>&lt;p&gt;&lt;/p&gt; &lt;p&gt;The&amp;nbsp;ListCollectionView is a WPF wrapper for an IList. When you add or remove something&amp;nbsp;from the IList, the ListCollectionView must be notified of the change by calling its OnCollectionChanged method so it can sync with the IList.  &lt;p&gt;The problem is, OnCollectionChanged is a protected method i.e. we can&amp;#39;t access it from outside of a ListViewCollection object. This means we have to create a new class that inherits from ListCollectionView so we can have&amp;nbsp;the means to call OnCollectionChanged whenever we add or remove something from the IList object we are wrapping e.g.  &lt;p&gt;&lt;/p&gt;&lt;pre&gt;class StudentListView(ListCollectionView):
	def constructor(theClass as Class): 
		super(theClass.StudentList) 
		theClass.StudentListChanged += OnStudentListChanged
	
	def OnStudentListChanged(sender as object, e as StudentListChangedEventArgs):
		if e.ChangeMode == Class.ChangeMode.Add:
			args = NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Add,e.Student,e.Index)
		else
			args = NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Remove,e.Student,e.Index)
		OnCollectionChanged(args)
&lt;/pre&gt;
&lt;p&gt;So whenever the parent Class object fires its StudentListChanged event after adding or removing a Student from its StudentList, then the StudentListView object gets to call the OnCollectionChanged method it inherited from&amp;nbsp;ListCollectionView, allowing it to remain in sync with the underlying StudentList object.&lt;/p&gt;&lt;img src="http://devpinoy.org/aggbug.aspx?PostID=5492" width="1" height="1"&gt;</description><category domain="http://devpinoy.org/blogs/smash/archive/tags/design+patterns/default.aspx">design patterns</category><category domain="http://devpinoy.org/blogs/smash/archive/tags/.NET/default.aspx">.NET</category><category domain="http://devpinoy.org/blogs/smash/archive/tags/WPF/default.aspx">WPF</category></item><item><title>The ViewController and XAML</title><link>http://devpinoy.org/blogs/smash/archive/2006/10/05/The-ViewController-and-XAML.aspx</link><pubDate>Thu, 05 Oct 2006 18:58:58 GMT</pubDate><guid isPermaLink="false">99090821-4da1-4a75-98c2-a35884625ff7:5466</guid><dc:creator>smash</dc:creator><slash:comments>0</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://devpinoy.org/blogs/smash/rsscomments.aspx?PostID=5466</wfw:commentRss><comments>http://devpinoy.org/blogs/smash/archive/2006/10/05/The-ViewController-and-XAML.aspx#comments</comments><description>&lt;p&gt;About two nights ago, I learned how to use an external XAML in&amp;nbsp; a WPF application. It was so simple. Just read the XAML, parse it, and then wire the elements to your code.&amp;nbsp; Now if this is how we are supposed to code&amp;nbsp;in WPF, then I might just as well stick to WinForms. &lt;/p&gt; &lt;p&gt;Fortunately XAML was not designed like Winforms or even Webforms.&amp;nbsp;&amp;nbsp;The FrameworkElement in WPF has a DataContext property which is an object type. This means we can&amp;nbsp;feed it any kind of object that fits our purpose.&amp;nbsp; The great thing about this is, XAML has the capability to bind all the elements in the object tree to the root element's DataContext property.&amp;nbsp; All we have to do is&amp;nbsp;bind&amp;nbsp;an element's property or properties to the corresponding property or properties of the object&amp;nbsp;concerned&amp;nbsp;like so:&lt;/p&gt;&lt;pre class="csharpcode"&gt;&lt;span class="kwrd"&gt;&amp;lt;&lt;/span&gt;&lt;span class="html"&gt;StackPanel&lt;/span&gt;
    &lt;span class="attr"&gt;xmlns&lt;/span&gt;&lt;span class="kwrd"&gt;="http://schemas.microsoft.com/winfx/2006/xaml/presentation"&lt;/span&gt;
    &lt;span class="attr"&gt;xmlns:x&lt;/span&gt;&lt;span class="kwrd"&gt;="http://schemas.microsoft.com/winfx/2006/xaml"&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;
    &lt;span class="kwrd"&gt;&amp;lt;&lt;/span&gt;&lt;span class="html"&gt;ListBox&lt;/span&gt;
        &lt;span class="attr"&gt;Name&lt;/span&gt;&lt;span class="kwrd"&gt;="listBox1"&lt;/span&gt;
        &lt;span class="attr"&gt;IsSynchronizedWithCurrentItem&lt;/span&gt;&lt;span class="kwrd"&gt;="true"&lt;/span&gt;
        &lt;span class="attr"&gt;ItemsSource&lt;/span&gt;&lt;span class="kwrd"&gt;="{Binding Path=Employees}"&lt;/span&gt;&lt;span class="kwrd"&gt;/&amp;gt;&lt;/span&gt;
    &lt;span class="kwrd"&gt;&amp;lt;&lt;/span&gt;&lt;span class="html"&gt;Button&lt;/span&gt;
        &lt;span class="attr"&gt;CommandParameter&lt;/span&gt;&lt;span class="kwrd"&gt;="{Binding ElementName=listBox1}"&lt;/span&gt;
        &lt;span class="attr"&gt;Command&lt;/span&gt;&lt;span class="kwrd"&gt;="{Binding Path=DeleteEmployee}"&lt;/span&gt;
        &lt;span class="attr"&gt;Content&lt;/span&gt;&lt;span class="kwrd"&gt;="Delete"&lt;/span&gt;&lt;span class="kwrd"&gt;/&amp;gt;&lt;/span&gt;
&lt;span class="kwrd"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="html"&gt;StackPanel&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;p&gt;Assuming we have a class called CompanyViewController that exposes the properties Employees (ListCollectionView) and DeleteEmployee (ICommand), and the XAML is stored in EmployeeListView.xaml, the code to drive this XAML could simply look like this: &lt;/p&gt;&lt;pre&gt;class EmployeeListView(Window):
	def constructor(company as Company):
		# parse the element tree via the XamlReader
		streamReader = StreamReader("EmployeeListView.xaml")
		xmlreader = XmlReader.Create(streamReader)		
		view as Panel= XamlReader.Load(xmlreader)
                
                # give the view something to chew on
		view.DataContext = CompanyViewController(company)
		
		# display the view in the window
		self.Content = view
&lt;/pre&gt;
&lt;p&gt;If you are a TDD kind of guy, you have to feel that tingling sensation!&amp;nbsp; &lt;/p&gt;
&lt;div&gt;&lt;/div&gt;
&lt;p&gt;&lt;/p&gt;
&lt;div&gt;&lt;/div&gt;
&lt;div&gt;&lt;/div&gt;&lt;pre&gt;&lt;/pre&gt;&lt;img src="http://devpinoy.org/aggbug.aspx?PostID=5466" width="1" height="1"&gt;</description><category domain="http://devpinoy.org/blogs/smash/archive/tags/design+patterns/default.aspx">design patterns</category><category domain="http://devpinoy.org/blogs/smash/archive/tags/.NET/default.aspx">.NET</category><category domain="http://devpinoy.org/blogs/smash/archive/tags/boo/default.aspx">boo</category><category domain="http://devpinoy.org/blogs/smash/archive/tags/WPF/default.aspx">WPF</category><category domain="http://devpinoy.org/blogs/smash/archive/tags/XAML/default.aspx">XAML</category></item><item><title>XAML meets Boo</title><link>http://devpinoy.org/blogs/smash/archive/2006/10/04/XAMl-meets-Boo.aspx</link><pubDate>Wed, 04 Oct 2006 19:59:12 GMT</pubDate><guid isPermaLink="false">99090821-4da1-4a75-98c2-a35884625ff7:5451</guid><dc:creator>smash</dc:creator><slash:comments>1</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://devpinoy.org/blogs/smash/rsscomments.aspx?PostID=5451</wfw:commentRss><comments>http://devpinoy.org/blogs/smash/archive/2006/10/04/XAMl-meets-Boo.aspx#comments</comments><description>&lt;p&gt;My first impression with&amp;nbsp;XAML was that you get to play with it only if your building WPF apps in c#.&amp;nbsp; It seems the .NET3&amp;nbsp; c# compiler is the only one capable of compiling XAML markup and code into an executable file.&amp;nbsp; It&amp;nbsp;was a big letdown for Boo aficionados like me since XAML is clearly the way to go&amp;nbsp;when it comes to creating user interfaces in WPF.&amp;nbsp; &lt;/p&gt; &lt;p&gt;I was dead wrong.&amp;nbsp;It seems any .NET language like Boo can still leverage XAML with a simple workaround as illustrated by Rob Relyea on his post&amp;nbsp;about the &lt;a href="http://www.windows-now.com/blogs/rrelyea/archive/2005/04/27/codingstyles.aspx"&gt;3 Coding Styles for Avalon Applications&lt;/a&gt;.&lt;/p&gt; &lt;p&gt;To see if&amp;nbsp;Rob's workaround will work, I wrote the following markup in XamlPad and copy pasted it to a&amp;nbsp;file called "Exer1.xaml" in my Boo project. I didn't want the Boo compiler to touch&amp;nbsp;this markup at compile time so&amp;nbsp;I set its Build action property to None and its Copy to output directory property to PreserveNewest.&amp;nbsp; &lt;/p&gt;&lt;pre class="csharpcode"&gt;&lt;span class="kwrd"&gt;&amp;lt;&lt;/span&gt;&lt;span class="html"&gt;StackPanel&lt;/span&gt;
    &lt;span class="attr"&gt;xmlns&lt;/span&gt;&lt;span class="kwrd"&gt;="http://schemas.microsoft.com/winfx/2006/xaml/presentation"&lt;/span&gt;
    &lt;span class="attr"&gt;xmlns:x&lt;/span&gt;&lt;span class="kwrd"&gt;="http://schemas.microsoft.com/winfx/2006/xaml"&lt;/span&gt;
    &lt;span class="attr"&gt;Margin&lt;/span&gt;&lt;span class="kwrd"&gt;="10"&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;
    &lt;span class="kwrd"&gt;&amp;lt;&lt;/span&gt;&lt;span class="html"&gt;DockPanel&lt;/span&gt;     &lt;span class="attr"&gt;Width&lt;/span&gt;&lt;span class="kwrd"&gt;="300"&lt;/span&gt; &lt;span class="attr"&gt;HorizontalAlignment&lt;/span&gt;&lt;span class="kwrd"&gt;="Left"&lt;/span&gt;    &lt;span class="attr"&gt;Margin&lt;/span&gt;&lt;span class="kwrd"&gt;="10 0 0 5"&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;
        &lt;span class="kwrd"&gt;&amp;lt;&lt;/span&gt;&lt;span class="html"&gt;StackPanel&lt;/span&gt; &lt;span class="attr"&gt;DockPanel&lt;/span&gt;.&lt;span class="attr"&gt;Dock&lt;/span&gt;&lt;span class="kwrd"&gt;="Left"&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;
            &lt;span class="kwrd"&gt;&amp;lt;&lt;/span&gt;&lt;span class="html"&gt;TextBox&lt;/span&gt;
                &lt;span class="attr"&gt;Name&lt;/span&gt;&lt;span class="kwrd"&gt;="textBox1"&lt;/span&gt;
                &lt;span class="attr"&gt;Width&lt;/span&gt;&lt;span class="kwrd"&gt;="230"&lt;/span&gt;
                &lt;span class="attr"&gt;FontSize&lt;/span&gt;&lt;span class="kwrd"&gt;="12"&lt;/span&gt;
                &lt;span class="attr"&gt;FontFamily&lt;/span&gt;&lt;span class="kwrd"&gt;="Tahoma"&lt;/span&gt;
                &lt;span class="attr"&gt;Margin&lt;/span&gt;&lt;span class="kwrd"&gt;="0 0 2 2"&lt;/span&gt;&lt;span class="kwrd"&gt;/&amp;gt;&lt;/span&gt;
        &lt;span class="kwrd"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="html"&gt;StackPanel&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;
        &lt;span class="kwrd"&gt;&amp;lt;&lt;/span&gt;&lt;span class="html"&gt;Button&lt;/span&gt;
            &lt;span class="attr"&gt;Name&lt;/span&gt;&lt;span class="kwrd"&gt;="addButton"&lt;/span&gt;
            &lt;span class="attr"&gt;DockPanel&lt;/span&gt;.&lt;span class="attr"&gt;Dock&lt;/span&gt;&lt;span class="kwrd"&gt;="Right"&lt;/span&gt;
            &lt;span class="attr"&gt;VerticalAlignment&lt;/span&gt;&lt;span class="kwrd"&gt;="Top"&lt;/span&gt;
            &lt;span class="attr"&gt;Width&lt;/span&gt;&lt;span class="kwrd"&gt;="60"&lt;/span&gt;
            &lt;span class="attr"&gt;Content&lt;/span&gt;&lt;span class="kwrd"&gt;="Add"&lt;/span&gt;&lt;span class="kwrd"&gt;/&amp;gt;&lt;/span&gt;
    &lt;span class="kwrd"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="html"&gt;DockPanel&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;
    &lt;span class="kwrd"&gt;&amp;lt;&lt;/span&gt;&lt;span class="html"&gt;DockPanel&lt;/span&gt; &lt;span class="attr"&gt;HorizontalAlignment&lt;/span&gt;&lt;span class="kwrd"&gt;="Left"&lt;/span&gt; &lt;span class="attr"&gt;Width&lt;/span&gt;&lt;span class="kwrd"&gt;="300"&lt;/span&gt; &lt;span class="attr"&gt;Margin&lt;/span&gt;&lt;span class="kwrd"&gt;="10 0 0 0"&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;
        &lt;span class="kwrd"&gt;&amp;lt;&lt;/span&gt;&lt;span class="html"&gt;StackPanel&lt;/span&gt; &lt;span class="attr"&gt;DockPanel&lt;/span&gt;.&lt;span class="attr"&gt;Dock&lt;/span&gt;&lt;span class="kwrd"&gt;="Left"&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;
            &lt;span class="kwrd"&gt;&amp;lt;&lt;/span&gt;&lt;span class="html"&gt;ListBox&lt;/span&gt;
                &lt;span class="attr"&gt;Name&lt;/span&gt;&lt;span class="kwrd"&gt;="listBox1"&lt;/span&gt;
                &lt;span class="attr"&gt;Width&lt;/span&gt;&lt;span class="kwrd"&gt;="230"&lt;/span&gt;
                &lt;span class="attr"&gt;Height&lt;/span&gt;&lt;span class="kwrd"&gt;="100"&lt;/span&gt;
                &lt;span class="attr"&gt;FontSize&lt;/span&gt;&lt;span class="kwrd"&gt;="12"&lt;/span&gt;
                &lt;span class="attr"&gt;FontFamily&lt;/span&gt;&lt;span class="kwrd"&gt;="Tahoma"&lt;/span&gt;
                &lt;span class="attr"&gt;Background&lt;/span&gt;&lt;span class="kwrd"&gt;="GhostWhite"&lt;/span&gt;
                &lt;span class="attr"&gt;Margin&lt;/span&gt;&lt;span class="kwrd"&gt;="0 0 2 2"&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;            
            &lt;span class="kwrd"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="html"&gt;ListBox&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;
        &lt;span class="kwrd"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="html"&gt;StackPanel&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;
        &lt;span class="kwrd"&gt;&amp;lt;&lt;/span&gt;&lt;span class="html"&gt;Button&lt;/span&gt;
            &lt;span class="attr"&gt;Name&lt;/span&gt;&lt;span class="kwrd"&gt;="delButton"&lt;/span&gt;
            &lt;span class="attr"&gt;DockPanel&lt;/span&gt;.&lt;span class="attr"&gt;Dock&lt;/span&gt;&lt;span class="kwrd"&gt;="Right"&lt;/span&gt;
            &lt;span class="attr"&gt;VerticalAlignment&lt;/span&gt;&lt;span class="kwrd"&gt;="Top"&lt;/span&gt;
            &lt;span class="attr"&gt;Width&lt;/span&gt;&lt;span class="kwrd"&gt;="60"&lt;/span&gt;
            &lt;span class="attr"&gt;Content&lt;/span&gt;&lt;span class="kwrd"&gt;="Delete"&lt;/span&gt;&lt;span class="kwrd"&gt;/&amp;gt;&lt;/span&gt;
    &lt;span class="kwrd"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="html"&gt;DockPanel&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;
&lt;span class="kwrd"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="html"&gt;StackPanel&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;
&lt;/pre&gt;
&lt;p&gt;&lt;/p&gt;&lt;a title="Create the markup with XamlPad" href="http://www.flickr.com/photos/73686286@N00/260971125/"&gt;&lt;img alt="Create the markup with XamlPad" hspace="0" src="http://static.flickr.com/104/260971125_327e959a92.jpg" border="0"&gt;&lt;/a&gt; 
&lt;p&gt;Next, I&amp;nbsp;added the following Boo code to the project.&amp;nbsp; The logic of the program is simple. When you click on the Add button (addButton), whatever you enter in the TextBox (textBox1) is placed on the ListBox (listBox1) below it.&amp;nbsp; When you click on the Delete button (delButton), the selected item on the listbox will be removed.&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;&lt;pre&gt;namespace WinFx.Demo

import System
import System.Collections
import System.Windows
import System.Windows.Controls
import System.Windows.Controls.Primitives
import System.Windows.Input
import System.Windows.Media
import System.Windows.Markup
import System.Windows.Shapes
import System.IO
import System.Xml

class Exer1(Window):
	textBox1 as TextBox 
	listBox1 as ListBox
	addButton as Button
	delButton as Button
	
	def constructor():
		# parse the element tree via the XamlReader
		streamReader = StreamReader("Exer1.xaml")
		xmlreader = XmlReader.Create(streamReader)		
		view as Panel= XamlReader.Load(xmlreader)
		
		# get a reference to the named elements via the LogicalTreeHelper
		textBox1  = LogicalTreeHelper.FindLogicalNode(view, "textBox1")
		listBox1  = LogicalTreeHelper.FindLogicalNode(view, "listBox1")
		addButton  = LogicalTreeHelper.FindLogicalNode(view, "addButton")
		delButton  = LogicalTreeHelper.FindLogicalNode(view, "delButton")
		
		# wire up the elements to your code
		addButton.Click += AddButtonClick
		delButton.Click += DelButtonClick		
		
		# customize the window 
		self.Content = view
		self.WindowStartupLocation = WindowStartupLocation.CenterScreen
		self.Title = "XAML Meets Boo"
		self.Width = 500
		self.Height = 300
		
	protected def AddButtonClick(sender as object, e as RoutedEventArgs):
		listBox1.Items.Add(textBox1.Text)
		textBox1.Text = ""
		textBox1.Focus()
			
	protected def DelButtonClick(sender as object, e as RoutedEventArgs):
		index = listBox1.SelectedIndex
		if index &amp;gt;= 0:
			listBox1.Items.RemoveAt(index)
			
		
[STAThread]
def Main():
	app = Application()	
	Exer1().Show()
	app.Run()
&lt;/pre&gt;
&lt;p&gt;Here's a screenshot of this in action.&lt;/p&gt;
&lt;p&gt;&lt;a title="Wiring XAML elements to code" href="http://www.flickr.com/photos/73686286@N00/260971135/"&gt;&lt;img alt="Wiring XAML elements to code" hspace="0" src="http://static.flickr.com/84/260971135_2966dc7010.jpg" border="0"&gt;&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;The code above looks very much like a regular WinForm code except the contents of the window are defined in an external XAML file. Shades of ASP.NET? One of the neat things about this scenario is that I can retouch the XAML sometime later using Sparkle for some eyecandy effects and then run the same app again with no recompilation whatsoever.&amp;nbsp; &lt;/p&gt;&lt;img src="http://devpinoy.org/aggbug.aspx?PostID=5451" width="1" height="1"&gt;</description><category domain="http://devpinoy.org/blogs/smash/archive/tags/.NET/default.aspx">.NET</category><category domain="http://devpinoy.org/blogs/smash/archive/tags/boo/default.aspx">boo</category><category domain="http://devpinoy.org/blogs/smash/archive/tags/WPF/default.aspx">WPF</category><category domain="http://devpinoy.org/blogs/smash/archive/tags/XAML/default.aspx">XAML</category></item><item><title>ColorChart XAML code bug resolved</title><link>http://devpinoy.org/blogs/smash/archive/2006/09/30/ColorChart-XAML-code-bug-resolved.aspx</link><pubDate>Sat, 30 Sep 2006 10:35:46 GMT</pubDate><guid isPermaLink="false">99090821-4da1-4a75-98c2-a35884625ff7:5392</guid><dc:creator>smash</dc:creator><slash:comments>0</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://devpinoy.org/blogs/smash/rsscomments.aspx?PostID=5392</wfw:commentRss><comments>http://devpinoy.org/blogs/smash/archive/2006/09/30/ColorChart-XAML-code-bug-resolved.aspx#comments</comments><description>&lt;p&gt;Well what can i say except, my apologies to the XAML team.&amp;nbsp; I was reviewing&amp;nbsp;the XAML code from my last post and there you go, I forgot to set the HorizontalAlignment to Center which was present on the Boo code. After inserting the appropriate setter the problem went away. Here's the correct XAML code for the ColorChart:&lt;/p&gt;&lt;pre class="csharpcode"&gt;&lt;span class="kwrd"&gt;&amp;lt;&lt;/span&gt;&lt;span class="html"&gt;Page&lt;/span&gt; &lt;span class="attr"&gt;x:Class&lt;/span&gt;&lt;span class="kwrd"&gt;="ColorChart.Page1"&lt;/span&gt;
    &lt;span class="attr"&gt;xmlns&lt;/span&gt;&lt;span class="kwrd"&gt;="http://schemas.microsoft.com/winfx/2006/xaml/presentation"&lt;/span&gt;
    &lt;span class="attr"&gt;xmlns:x&lt;/span&gt;&lt;span class="kwrd"&gt;="http://schemas.microsoft.com/winfx/2006/xaml"&lt;/span&gt;
    &lt;span class="attr"&gt;Title&lt;/span&gt;&lt;span class="kwrd"&gt;="Page1"&lt;/span&gt;
    &lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;
    &lt;span class="kwrd"&gt;&amp;lt;&lt;/span&gt;&lt;span class="html"&gt;Page.Resources&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;
        &lt;span class="kwrd"&gt;&amp;lt;&lt;/span&gt;&lt;span class="html"&gt;Style&lt;/span&gt; &lt;span class="attr"&gt;x:Key&lt;/span&gt;&lt;span class="kwrd"&gt;="CCStyle"&lt;/span&gt; &lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;
            &lt;span class="kwrd"&gt;&amp;lt;&lt;/span&gt;&lt;span class="html"&gt;Setter&lt;/span&gt; &lt;span class="attr"&gt;Property&lt;/span&gt;&lt;span class="kwrd"&gt;="Control.BorderBrush"&lt;/span&gt; &lt;span class="attr"&gt;Value&lt;/span&gt;&lt;span class="kwrd"&gt;="LightGray"&lt;/span&gt;&lt;span class="kwrd"&gt;/&amp;gt;&lt;/span&gt;
            &lt;span class="kwrd"&gt;&amp;lt;&lt;/span&gt;&lt;span class="html"&gt;Setter&lt;/span&gt; &lt;span class="attr"&gt;Property&lt;/span&gt;&lt;span class="kwrd"&gt;="Control.BorderThickness"&lt;/span&gt; &lt;span class="attr"&gt;Value&lt;/span&gt;&lt;span class="kwrd"&gt;="1"&lt;/span&gt;&lt;span class="kwrd"&gt;/&amp;gt;&lt;/span&gt;
            &lt;span class="kwrd"&gt;&amp;lt;&lt;/span&gt;&lt;span class="html"&gt;Setter&lt;/span&gt; &lt;span class="attr"&gt;Property&lt;/span&gt;&lt;span class="kwrd"&gt;="Control.Margin"&lt;/span&gt; &lt;span class="attr"&gt;Value&lt;/span&gt;&lt;span class="kwrd"&gt;="3"&lt;/span&gt;&lt;span class="kwrd"&gt;/&amp;gt;&lt;/span&gt;
            &lt;u&gt;&lt;span class="kwrd"&gt;&amp;lt;&lt;/span&gt;&lt;span class="html"&gt;Setter&lt;/span&gt; &lt;span class="attr"&gt;Property&lt;/span&gt;&lt;span class="kwrd"&gt;="Control.HorizontalAlignment"&lt;/span&gt; &lt;span class="attr"&gt;Value&lt;/span&gt;&lt;span class="kwrd"&gt;="Center"&lt;/span&gt;&lt;span class="kwrd"&gt;/&amp;gt;&lt;/span&gt;&lt;/u&gt;
        &lt;span class="kwrd"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="html"&gt;Style&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;
        &lt;span class="kwrd"&gt;&amp;lt;&lt;/span&gt;&lt;span class="html"&gt;ItemsPanelTemplate&lt;/span&gt; &lt;span class="attr"&gt;x:Key&lt;/span&gt;&lt;span class="kwrd"&gt;="CCPanel"&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;
            &lt;span class="kwrd"&gt;&amp;lt;&lt;/span&gt;&lt;span class="html"&gt;UniformGrid&lt;/span&gt; &lt;span class="attr"&gt;Columns&lt;/span&gt;&lt;span class="kwrd"&gt;="6"&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&amp;lt;/&lt;/span&gt;&lt;span class="html"&gt;UniformGrid&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;
        &lt;span class="kwrd"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="html"&gt;ItemsPanelTemplate&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;
        &lt;span class="kwrd"&gt;&amp;lt;&lt;/span&gt;&lt;span class="html"&gt;DataTemplate&lt;/span&gt; &lt;span class="attr"&gt;x:Key&lt;/span&gt;&lt;span class="kwrd"&gt;="CCTemplate"&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;
            &lt;span class="kwrd"&gt;&amp;lt;&lt;/span&gt;&lt;span class="html"&gt;StackPanel&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;
                &lt;span class="kwrd"&gt;&amp;lt;&lt;/span&gt;&lt;span class="html"&gt;Rectangle&lt;/span&gt;     
                    &lt;span class="attr"&gt;Width&lt;/span&gt;&lt;span class="kwrd"&gt;="100"&lt;/span&gt; 
                    &lt;span class="attr"&gt;Height&lt;/span&gt;&lt;span class="kwrd"&gt;="40"&lt;/span&gt; 
                    &lt;span class="attr"&gt;Fill&lt;/span&gt;&lt;span class="kwrd"&gt;="{Binding Path=Brush}"&lt;/span&gt; &lt;span class="kwrd"&gt;/&amp;gt;&lt;/span&gt;
                &lt;span class="kwrd"&gt;&amp;lt;&lt;/span&gt;&lt;span class="html"&gt;TextBlock&lt;/span&gt; 
                    &lt;span class="attr"&gt;FontSize&lt;/span&gt;&lt;span class="kwrd"&gt;="11"&lt;/span&gt; 
                    &lt;span class="attr"&gt;Text&lt;/span&gt;&lt;span class="kwrd"&gt;="{Binding Path=Name}"&lt;/span&gt; 
                    &lt;span class="attr"&gt;HorizontalAlignment&lt;/span&gt;&lt;span class="kwrd"&gt;="Center"&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;
                &lt;span class="kwrd"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="html"&gt;TextBlock&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;
            &lt;span class="kwrd"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="html"&gt;StackPanel&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;
        &lt;span class="kwrd"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="html"&gt;DataTemplate&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;
    &lt;span class="kwrd"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="html"&gt;Page.Resources&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;
    &lt;span class="kwrd"&gt;&amp;lt;&lt;/span&gt;&lt;span class="html"&gt;ListBox&lt;/span&gt; 
        &lt;span class="attr"&gt;Name&lt;/span&gt;&lt;span class="kwrd"&gt;="listBox1"&lt;/span&gt; 
        &lt;span class="attr"&gt;SelectionMode&lt;/span&gt;&lt;span class="kwrd"&gt;="Single"&lt;/span&gt; 
        &lt;span class="attr"&gt;ItemsPanel&lt;/span&gt;&lt;span class="kwrd"&gt;="{StaticResource CCPanel}"&lt;/span&gt; 
        &lt;span class="attr"&gt;ItemTemplate&lt;/span&gt;&lt;span class="kwrd"&gt;="{StaticResource CCTemplate}"&lt;/span&gt; 
        &lt;span class="attr"&gt;ItemContainerStyle&lt;/span&gt;&lt;span class="kwrd"&gt;="{StaticResource CCStyle}"&lt;/span&gt;&lt;span class="kwrd"&gt;/&amp;gt;&lt;/span&gt;
&lt;span class="kwrd"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="html"&gt;Page&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;
&lt;/pre&gt;
&lt;p&gt;Now here's the result:&lt;/p&gt;&lt;a title="Color Chart XBAP Demo Updated" href="http://www.flickr.com/photos/73686286@N00/256312518/"&gt;&lt;img alt="Color Chart XBAP Demo Updated" hspace="0" src="http://static.flickr.com/79/256312518_f89f1aef57.jpg" border="0"&gt;&lt;/a&gt;&lt;img src="http://devpinoy.org/aggbug.aspx?PostID=5392" width="1" height="1"&gt;</description><category domain="http://devpinoy.org/blogs/smash/archive/tags/XAML/default.aspx">XAML</category></item><item><title>XAML renders differently</title><link>http://devpinoy.org/blogs/smash/archive/2006/09/30/XAML-renders-differently.aspx</link><pubDate>Fri, 29 Sep 2006 20:28:59 GMT</pubDate><guid isPermaLink="false">99090821-4da1-4a75-98c2-a35884625ff7:5386</guid><dc:creator>smash</dc:creator><slash:comments>3</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://devpinoy.org/blogs/smash/rsscomments.aspx?PostID=5386</wfw:commentRss><comments>http://devpinoy.org/blogs/smash/archive/2006/09/30/XAML-renders-differently.aspx#comments</comments><description>&lt;p&gt;I was reading with great interest &lt;a href="http://community.devpinoy.org/blogs/keithrull/archive/2006/09/26/How-To_3A00_-Creating-a-.NET-Color-Chart-revisited-.aspx"&gt;Keith's posts about creating a color chart in ASP.NET&lt;/a&gt; and decided to roll out a similar WPF application in pure code first - in Boo ofcourse - &amp;nbsp;and in XAML second. The former will be a Windows application&amp;nbsp;and the latter will be an XBAP application so I can run it inside a browser - just like Keith's demo.&amp;nbsp; &lt;/p&gt; &lt;p&gt;The motivation for this came about when I realized that the color chart can easily be rendered&amp;nbsp;using the WPF ListBox.&amp;nbsp; The trick was to set the ItemsPanel property of the ListBox to a template containing a WPF UniformGrid.&lt;/p&gt; &lt;p&gt;Coding the windows version in Boo was a breeze.&amp;nbsp; All in all it took only about 20 minutes to get it up and running since Keith&amp;nbsp;had&amp;nbsp;mapped the whole thing already.&amp;nbsp;I used &lt;a href="http://community.devpinoy.org/blogs/keithrull/archive/2006/09/25/How-To_3A00_-Create-a-.NET-Color-Chart-using-Reflection-.aspx"&gt;Keith's original method of using Reflection&lt;/a&gt; to get the list of&amp;nbsp;predefined colors and adapted it&amp;nbsp;for WPF.&amp;nbsp; &lt;/p&gt; &lt;pre&gt;
    class ColorService:
	static def GetBrushes() as System.Collections.IEnumerable:
		for propertyInfo as PropertyInfo in typeof(Brushes).GetProperties():
			memberInfo = cast(MemberInfo, propertyInfo)
			brush = cast(Brush,propertyInfo.GetValue(null,null))
			yield NamedBrush(memberInfo.Name, brush)
			
	class NamedBrush:
		[getter(Name)] _name as string
		[getter(Brush)] _brush as Brush
		
		def constructor(name as string, brush as Brush):
			_name = name
			_brush = brush
	
		override def ToString():
			return _name
&lt;/pre&gt;
&lt;p&gt;Here's the c# version:&lt;/p&gt;
&lt;pre&gt;   
    public class ColorService
    {
        static public IEnumerable GetBrushes()
        {
            foreach (PropertyInfo propertyInfo in typeof(Brushes).GetProperties())
            {
                MemberInfo memberInfo = (MemberInfo)propertyInfo;
                Brush brushValue = (Brush)propertyInfo.GetValue(null, null);
                yield return new NamedBrush(memberInfo.Name, brushValue);
            }
        }

        public class NamedBrush
        {
            public NamedBrush(string name, Brush brush)
            {
                _name = name;
                _brush = brush;
            }

            public string Name
            {
                get { return _name; }
            }

            public Brush Brush
            {
                get { return _brush; }
            }

            public override string ToString()
            {
                return _name;
            }

            string _name;
            Brush _brush;
        }
    }
&lt;/pre&gt;
&lt;p&gt;Here's how the windows app looks like:&lt;/p&gt;&lt;a title="Color Chart Demo" href="http://www.flickr.com/photos/73686286@N00/255927833/"&gt;&lt;img alt="Color Chart Demo" hspace="0" src="http://static.flickr.com/70/255927833_0032356213.jpg" border="0"&gt;&lt;/a&gt; 
&lt;p&gt;Now converting the app into XBAP took quite some time to finish since I'm not well versed in XAML yet. I had to check the Boo layout code repeatedly to get the XAML finally working.&amp;nbsp; Heres the XAML layout code:&lt;/p&gt;&lt;pre class="csharpcode"&gt;&lt;span class="kwrd"&gt;&amp;lt;&lt;/span&gt;&lt;span class="html"&gt;Page&lt;/span&gt; &lt;span class="attr"&gt;x:Class&lt;/span&gt;&lt;span class="kwrd"&gt;="ColorChart.Page1"&lt;/span&gt;
    &lt;span class="attr"&gt;xmlns&lt;/span&gt;&lt;span class="kwrd"&gt;="http://schemas.microsoft.com/winfx/2006/xaml/presentation"&lt;/span&gt;
    &lt;span class="attr"&gt;xmlns:x&lt;/span&gt;&lt;span class="kwrd"&gt;="http://schemas.microsoft.com/winfx/2006/xaml"&lt;/span&gt;
    &lt;span class="attr"&gt;Title&lt;/span&gt;&lt;span class="kwrd"&gt;="Page1"&lt;/span&gt;
    &lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;
    &lt;span class="kwrd"&gt;&amp;lt;&lt;/span&gt;&lt;span class="html"&gt;Page.Resources&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;
        &lt;span class="kwrd"&gt;&amp;lt;&lt;/span&gt;&lt;span class="html"&gt;Style&lt;/span&gt; &lt;span class="attr"&gt;x:Key&lt;/span&gt;&lt;span class="kwrd"&gt;="CCStyle"&lt;/span&gt; &lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;
            &lt;span class="kwrd"&gt;&amp;lt;&lt;/span&gt;&lt;span class="html"&gt;Setter&lt;/span&gt; &lt;span class="attr"&gt;Property&lt;/span&gt;&lt;span class="kwrd"&gt;="Control.BorderBrush"&lt;/span&gt; &lt;span class="attr"&gt;Value&lt;/span&gt;&lt;span class="kwrd"&gt;="LightGray"&lt;/span&gt;&lt;span class="kwrd"&gt;/&amp;gt;&lt;/span&gt;
            &lt;span class="kwrd"&gt;&amp;lt;&lt;/span&gt;&lt;span class="html"&gt;Setter&lt;/span&gt; &lt;span class="attr"&gt;Property&lt;/span&gt;&lt;span class="kwrd"&gt;="Control.BorderThickness"&lt;/span&gt; &lt;span class="attr"&gt;Value&lt;/span&gt;&lt;span class="kwrd"&gt;="1"&lt;/span&gt;&lt;span class="kwrd"&gt;/&amp;gt;&lt;/span&gt;
            &lt;span class="kwrd"&gt;&amp;lt;&lt;/span&gt;&lt;span class="html"&gt;Setter&lt;/span&gt; &lt;span class="attr"&gt;Property&lt;/span&gt;&lt;span class="kwrd"&gt;="Control.Margin"&lt;/span&gt; &lt;span class="attr"&gt;Value&lt;/span&gt;&lt;span class="kwrd"&gt;="3"&lt;/span&gt;&lt;span class="kwrd"&gt;/&amp;gt;&lt;/span&gt;
        &lt;span class="kwrd"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="html"&gt;Style&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;
        &lt;span class="kwrd"&gt;&amp;lt;&lt;/span&gt;&lt;span class="html"&gt;ItemsPanelTemplate&lt;/span&gt; &lt;span class="attr"&gt;x:Key&lt;/span&gt;&lt;span class="kwrd"&gt;="CCPanel"&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;
            &lt;span class="kwrd"&gt;&amp;lt;&lt;/span&gt;&lt;span class="html"&gt;UniformGrid&lt;/span&gt; &lt;span class="attr"&gt;Columns&lt;/span&gt;&lt;span class="kwrd"&gt;="6"&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&amp;lt;/&lt;/span&gt;&lt;span class="html"&gt;UniformGrid&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;
        &lt;span class="kwrd"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="html"&gt;ItemsPanelTemplate&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;
        &lt;span class="kwrd"&gt;&amp;lt;&lt;/span&gt;&lt;span class="html"&gt;DataTemplate&lt;/span&gt; &lt;span class="attr"&gt;x:Key&lt;/span&gt;&lt;span class="kwrd"&gt;="CCTemplate"&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;
            &lt;span class="kwrd"&gt;&amp;lt;&lt;/span&gt;&lt;span class="html"&gt;StackPanel&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;
                &lt;span class="kwrd"&gt;&amp;lt;&lt;/span&gt;&lt;span class="html"&gt;Rectangle&lt;/span&gt;     
                    &lt;span class="attr"&gt;Width&lt;/span&gt;&lt;span class="kwrd"&gt;="100"&lt;/span&gt; 
                    &lt;span class="attr"&gt;Height&lt;/span&gt;&lt;span class="kwrd"&gt;="40"&lt;/span&gt; 
                    &lt;span class="attr"&gt;Fill&lt;/span&gt;&lt;span class="kwrd"&gt;="{Binding Path=Brush}"&lt;/span&gt; 
                    &lt;span class="attr"&gt;HorizontalAlignment&lt;/span&gt;&lt;span class="kwrd"&gt;="Left"&lt;/span&gt;&lt;span class="kwrd"&gt;/&amp;gt;&lt;/span&gt;
                &lt;span class="kwrd"&gt;&amp;lt;&lt;/span&gt;&lt;span class="html"&gt;TextBlock&lt;/span&gt; 
                    &lt;span class="attr"&gt;FontSize&lt;/span&gt;&lt;span class="kwrd"&gt;="11"&lt;/span&gt; 
                    &lt;span class="attr"&gt;Text&lt;/span&gt;&lt;span class="kwrd"&gt;="{Binding Path=Name}"&lt;/span&gt; 
                    &lt;span class="attr"&gt;HorizontalAlignment&lt;/span&gt;&lt;span class="kwrd"&gt;="Center"&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;
                &lt;span class="kwrd"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="html"&gt;TextBlock&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;
            &lt;span class="kwrd"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="html"&gt;StackPanel&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;
        &lt;span class="kwrd"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="html"&gt;DataTemplate&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;
    &lt;span class="kwrd"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="html"&gt;Page.Resources&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;
    &lt;span class="kwrd"&gt;&amp;lt;&lt;/span&gt;&lt;span class="html"&gt;ListBox&lt;/span&gt; 
        &lt;span class="attr"&gt;Name&lt;/span&gt;&lt;span class="kwrd"&gt;="listBox1"&lt;/span&gt; 
        &lt;span class="attr"&gt;SelectionMode&lt;/span&gt;&lt;span class="kwrd"&gt;="Single"&lt;/span&gt; 
        &lt;span class="attr"&gt;ItemsPanel&lt;/span&gt;&lt;span class="kwrd"&gt;="{StaticResource CCPanel}"&lt;/span&gt; 
        &lt;span class="attr"&gt;ItemTemplate&lt;/span&gt;&lt;span class="kwrd"&gt;="{StaticResource CCTemplate}"&lt;/span&gt; 
        &lt;span class="attr"&gt;ItemContainerStyle&lt;/span&gt;&lt;span class="kwrd"&gt;="{StaticResource CCStyle}"&lt;/span&gt;&lt;span class="kwrd"&gt;/&amp;gt;&lt;/span&gt;
&lt;span class="kwrd"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="html"&gt;Page&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;
&lt;/pre&gt;
&lt;p&gt;This is the c# code-behind for the XAML above:&lt;/p&gt;&lt;pre class="csharpcode"&gt;&lt;span class="kwrd"&gt;namespace&lt;/span&gt; ColorChart
{
    &lt;span class="kwrd"&gt;public&lt;/span&gt; &lt;span class="kwrd"&gt;partial&lt;/span&gt; &lt;span class="kwrd"&gt;class&lt;/span&gt; Page1 : System.Windows.Controls.Page
    {
        &lt;span class="kwrd"&gt;public&lt;/span&gt; Page1()
        {
            InitializeComponent();
            &lt;span class="kwrd"&gt;this&lt;/span&gt;.listBox1.ItemsSource = ColorService.GetBrushes();
        }
    }
}&lt;/pre&gt;
&lt;p&gt;And here's the layout code in Boo which does thesame thing as the XAML above:&lt;/p&gt;&lt;pre class="csharpcode"&gt;&lt;span class="kwrd"&gt;class&lt;/span&gt; CCStyle(Style):
    def constructor():
        s1 = Setter(ListBoxItem.BorderThicknessProperty, Thickness(1))
        s2 = Setter(ListBoxItem.MarginProperty, Thickness(3))
        s3 = Setter(ListBoxItem.BorderBrushProperty, Brushes.LightGray)
        s4 = Setter(ListBoxItem.HorizontalAlignmentProperty, HorizontalAlignment.Center)
        self.Setters.Add(s1)
        self.Setters.Add(s2)
        self.Setters.Add(s3)
        self.Setters.Add(s4)

&lt;span class="kwrd"&gt;class&lt;/span&gt; CCPanel(ItemsPanelTemplate):
    def constructor():
        root = FrameworkElementFactory(UniformGrid)
        root.SetValue(UniformGrid.ColumnsProperty, 6)
        self.VisualTree = root

&lt;span class="kwrd"&gt;class&lt;/span&gt; CCTemplate(DataTemplate):
    def constructor():
        root = FrameworkElementFactory(StackPanel)
        ch1 = FrameworkElementFactory(Rectangle)
        ch1.SetValue(Rectangle.WidthProperty, 100.0)
        ch1.SetValue(Rectangle.HeightProperty, 40.0)
        ch1.SetValue(Rectangle.FillProperty, Binding(&lt;span class="str"&gt;"Brush"&lt;/span&gt;))
        ch2 = FrameworkElementFactory(TextBlock)
        ch2.SetValue(TextBlock.TextProperty, Binding(&lt;span class="str"&gt;"Name"&lt;/span&gt;))
        ch2.SetValue(TextBlock.HorizontalAlignmentProperty, HorizontalAlignment.Center)
        root.AppendChild(ch1)
        root.AppendChild(ch2)
        self.VisualTree = root
        
&lt;span class="kwrd"&gt;class&lt;/span&gt; ColorChartView(ListBox):
    def constructor():
        ItemContainerStyle = CCStyle()
        ItemsPanel = CCPanel()
        ItemTemplate = CCTemplate()
        ItemsSource = ColorService.GetBrushes()        &lt;/pre&gt;
&lt;p&gt;An XBAP application needs to be compiled and then published to an IIS server first.&amp;nbsp; After you have done that open your IE browser - or Firefox browser&amp;nbsp;if you have the &amp;nbsp;IE Tab extension installed&amp;nbsp;-&amp;nbsp;and&amp;nbsp;type in the url&amp;nbsp;of your application.&amp;nbsp; In my case I typed in &lt;a href="http://localhost/winfx/colorchart.xbap"&gt;http://localhost/winfx/colorchart.xbap&lt;/a&gt; and here's what came out:&lt;/p&gt;
&lt;p&gt;&lt;a title="Color Chart XBAP Demo" href="http://www.flickr.com/photos/73686286@N00/255927819/"&gt;&lt;img alt="Color Chart XBAP Demo" hspace="0" src="http://static.flickr.com/119/255927819_ca8b7160ab.jpg" border="0"&gt;&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;Now that was neat. The keyboard navigation and mouse selection works just like in the windows version.&amp;nbsp;But&amp;nbsp;if you will look at it more closely you'll notice that there's something different about the XAML rendered view. &lt;/p&gt;
&lt;p&gt;XAML by the way is tokenized into BAML during compilation and is embedded as a resource inside the executable file. Maybe the XAML team needs more time to tweak their engine. &lt;/p&gt;&lt;img src="http://devpinoy.org/aggbug.aspx?PostID=5386" width="1" height="1"&gt;</description><category domain="http://devpinoy.org/blogs/smash/archive/tags/c_2300_/default.aspx">c#</category><category domain="http://devpinoy.org/blogs/smash/archive/tags/.NET/default.aspx">.NET</category><category domain="http://devpinoy.org/blogs/smash/archive/tags/boo/default.aspx">boo</category><category domain="http://devpinoy.org/blogs/smash/archive/tags/WPF/default.aspx">WPF</category><category domain="http://devpinoy.org/blogs/smash/archive/tags/XAML/default.aspx">XAML</category></item><item><title>Not your father's ListBox</title><link>http://devpinoy.org/blogs/smash/archive/2006/09/28/Not-your-father_2700_s-ListBox.aspx</link><pubDate>Wed, 27 Sep 2006 21:08:41 GMT</pubDate><guid isPermaLink="false">99090821-4da1-4a75-98c2-a35884625ff7:5343</guid><dc:creator>smash</dc:creator><slash:comments>0</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://devpinoy.org/blogs/smash/rsscomments.aspx?PostID=5343</wfw:commentRss><comments>http://devpinoy.org/blogs/smash/archive/2006/09/28/Not-your-father_2700_s-ListBox.aspx#comments</comments><description>&lt;p&gt;[&lt;strong&gt;Edited&lt;/strong&gt;: &lt;em&gt;I changed the code to&amp;nbsp;use&amp;nbsp;one template this time to emphasize the&amp;nbsp;proper use of styling. I also moved the the definition for the style to a class to make the code cleaner.&lt;/em&gt;] &lt;/p&gt; &lt;p&gt;After only a couple of&amp;nbsp;days &amp;nbsp;hacking away at WPF using the SDK docs and&amp;nbsp;Google as reference, I may finally be gaining a toehold into the vast and exciting world of Avalon.&amp;nbsp; So many things about WPF are new e.g. &amp;nbsp;FrameworkElementFactory, DependencyProperty, DataTemplate and the list goes on.&amp;nbsp; If you are not careful you'll loose yourself following the inheritance heirarchy.&amp;nbsp; &lt;/p&gt; &lt;p&gt;I finally gave up doing that and decided that the best way to learn WPF was to&amp;nbsp;leave all those fancy stuff first - like&amp;nbsp;transformations, animation, 3D etc. - and work on the normal stuff like take some data from a service&amp;nbsp;object and display&amp;nbsp;the &amp;nbsp;information on the screen.&amp;nbsp; So to get the ball rolling, I whipped up a couple of&amp;nbsp;rudimentary classes -&amp;nbsp;Customer&amp;nbsp;and CustomerService.&amp;nbsp; After spending half a day pounding the keyboard, studying compiler error messages, checking the docs, googling, cursing - here's what i managed to do with the ListBox:&lt;/p&gt; &lt;p&gt;&lt;a title="ListBox Demo" href="http://www.flickr.com/photos/73686286@N00/254772516/"&gt;&lt;img alt="ListBox Demo" hspace="0" src="http://static.flickr.com/122/254772516_311fefc3f2.jpg" border="0"&gt;&lt;/a&gt;&lt;/p&gt; &lt;p&gt;Although styling and templating are indisputably easier to accomplish in XAML, I believe programmers must also know how to do these things in pure code. Knowing how things are done under the hood will prove invaluable in the long haul. The days when Web developers would smirk at the sight of our user interfaces are about to end.&lt;/p&gt; &lt;p&gt;&lt;/p&gt;&lt;pre&gt;import System
import System.Windows
import System.Windows.Controls
import System.Windows.Controls.Primitives
import System.Windows.Data
import System.Windows.Documents
import System.Windows.Input
import System.Windows.Markup
import System.Windows.Media
import System.Windows.Navigation
import System.Windows.Shapes
import System.Globalization

class Customer:
	[property(Name)] _name = ""
	[property(Address)] _addr = ""
	
	def constructor(name as string, addr as string):
		_name = name
		_addr = addr
	
	override def ToString() as string:
		return _name

class CustomerService:
	static def GetCustomers():
		yield Customer("brent","davao")
		yield Customer("manny","gsc")
		yield Customer("robert","cagayan")
		yield Customer("george","cebu")
		yield Customer("thomas","iloilo")
		yield Customer("lelanie","tagum")
		yield Customer("bong","digos")
		yield Customer("hazel","bicol")		
			
class CustomerTemplate(DataTemplate):
	def constructor():
		super(Customer)
		panel = FrameworkElementFactory(StackPanel)		
		child1 = FrameworkElementFactory(TextBlock)
		child1.SetValue(TextBlock.TextProperty, Binding("Name"))		
		child1.SetValue(TextBlock.FontSizeProperty, 20.0)
		child2 = FrameworkElementFactory(Label)
		child2.SetValue(Label.ContentProperty, Binding("Address"))		
		panel.AppendChild(child1)
		panel.AppendChild(child2)	
		self.VisualTree = panel
		
class CustomerStyle(Style):
	def constructor():
		super(ListBoxItem)
		setter1 = Setter(ListBoxItem.HorizontalContentAlignmentProperty, HorizontalAlignment.Stretch)
		setter2 = Setter(ListBoxItem.MarginProperty, Thickness(2))
		setter3 = Setter(ListBoxItem.BorderThicknessProperty, Thickness(1))
		setter4 = Setter(ListBox.BorderBrushProperty, Brushes.Gold)
		setter5 = Setter(ListBox.BackgroundProperty, Brushes.Bisque)
		setter6 = Setter(TextBlock.ForegroundProperty, Brushes.Orange)
		self.Setters.Add(setter1)
		self.Setters.Add(setter2)
		self.Setters.Add(setter3)
		self.Setters.Add(setter4)
		self.Setters.Add(setter5)
		self.Setters.Add(setter6)


class Home(Grid):
	def constructor():	
		self.ColumnDefinitions.Add(ColumnDefinition(Width:GridLength(200.0)))
		self.ColumnDefinitions.Add(ColumnDefinition(Width:GridLength(10.0)))
		self.ColumnDefinitions.Add(ColumnDefinition(Width:GridLength(400.0)))
		self.RowDefinitions.Add(RowDefinition(Height:GridLength(20.0)))
		self.RowDefinitions.Add(RowDefinition(Height:GridLength(100.0)))
		self.RowDefinitions.Add(RowDefinition(Height:GridLength(10.0)))
		self.RowDefinitions.Add(RowDefinition(Height:GridLength(100.0)))
		self.RowDefinitions.Add(RowDefinition(Height:GridLength(10.0)))
		self.RowDefinitions.Add(RowDefinition(Height:GridLength(200.0)))
		self.RowDefinitions.Add(RowDefinition(Height:GridLength(10.0)))
		
		regularListBox = ListBox()
		regularListBox.ItemsSource = CustomerService.GetCustomers()
		Grid.SetColumn(regularListBox,2)
		Grid.SetRow(regularListBox,1)
		
		templatedListBox = ListBox()
		templatedListBox.ItemTemplate = CustomerTemplate()	
		templatedListBox.ItemsSource = CustomerService.GetCustomers()
		Grid.SetColumn(templatedListBox,2)
		Grid.SetRow(templatedListBox,3)
		
		styledListBox = ListBox()			
		styledListBox.ItemContainerStyle = CustomerStyle()
		styledListBox.ItemTemplate = CustomerTemplate()
		styledListBox.ItemsSource = CustomerService.GetCustomers()						
		Grid.SetColumn(styledListBox,2)
		Grid.SetRow(styledListBox,5)
		
		text1 = TextBlock(Run("A Regular ListBox "))
		text1.FontSize = 14
		text1.HorizontalAlignment = HorizontalAlignment.Right
		text2 = TextBlock(Run("A Templated ListBox "))
		text2.FontSize = 14
		text2.HorizontalAlignment = HorizontalAlignment.Right
		text3 = TextBlock(Run("A Styled Templated ListBox "))
		text3.FontSize = 14
		text3.HorizontalAlignment = HorizontalAlignment.Right
		Grid.SetRow(text1,1)
		Grid.SetRow(text2,3)
		Grid.SetRow(text3,5)	
			
		self.Children.Add(regularListBox)
		self.Children.Add(templatedListBox)
		self.Children.Add(styledListBox)
		self.Children.Add(text1)
		self.Children.Add(text2)
		self.Children.Add(text3)				

[STAThread]
def Main():
	# define main window
	win = Window(Title:"ListBox Demo")	
	win.Content = Home()
	# define application
	app = Application()
	app.Startup += { win.Show() }
	app.Run()

&lt;/pre&gt;&lt;img src="http://devpinoy.org/aggbug.aspx?PostID=5343" width="1" height="1"&gt;</description><category domain="http://devpinoy.org/blogs/smash/archive/tags/.NET/default.aspx">.NET</category><category domain="http://devpinoy.org/blogs/smash/archive/tags/boo/default.aspx">boo</category><category domain="http://devpinoy.org/blogs/smash/archive/tags/WPF/default.aspx">WPF</category></item><item><title>WinFx TestDrive with Boo</title><link>http://devpinoy.org/blogs/smash/archive/2006/09/25/WinFx-TestDrive.aspx</link><pubDate>Sun, 24 Sep 2006 22:37:33 GMT</pubDate><guid isPermaLink="false">99090821-4da1-4a75-98c2-a35884625ff7:5268</guid><dc:creator>smash</dc:creator><slash:comments>0</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://devpinoy.org/blogs/smash/rsscomments.aspx?PostID=5268</wfw:commentRss><comments>http://devpinoy.org/blogs/smash/archive/2006/09/25/WinFx-TestDrive.aspx#comments</comments><description>&lt;p&gt;Learning&amp;nbsp;the ins and outs of WPF is like climbing Mount Apo for the first time - minus a guide.&amp;nbsp;Oh yes, judging by the sample applications you see on the Internet, Microsoft may have&amp;nbsp;succeeded in creating&amp;nbsp;a very compelling framework&amp;nbsp;that will&amp;nbsp;change the face of computing as we know it today.&amp;nbsp; The engineers who dared build this thing&amp;nbsp; has probably thrown in every&amp;nbsp;piece of&amp;nbsp; computing&amp;nbsp;gobbledygook ever imagined - including&amp;nbsp;the proverbial kitchen sink. &lt;/p&gt; &lt;p&gt;That kitchen sink may very well be the new markup language called XAML, which&amp;nbsp;those bloody engineers lovingly pronounce as zammel.&amp;nbsp; The fact that it is being hyped in every WPF literature as the de facto standard in writing the next generation UIs leaves me utterly breathless.&amp;nbsp;&amp;nbsp;WPF is all about&amp;nbsp;this new markup (XAML) and code-behind (C# or VB.NET) -&amp;nbsp;similar to the&amp;nbsp;combo made popular in WebForms.&amp;nbsp;&amp;nbsp; &lt;/p&gt; &lt;p&gt;Whatever similarities between&amp;nbsp;WebForms and WPF abruptly ends there. Even&amp;nbsp;a six year .NET&amp;nbsp;developer won't&amp;nbsp;have any comfort zones if that's any consolation.&amp;nbsp;&amp;nbsp;I&amp;nbsp;once had this illusion that since WPF is basically .NET, I will be hitting the ground running by the time I decided to&amp;nbsp;study WPF.&amp;nbsp; It actually felt more like being hit by a runaway truck.&amp;nbsp; Microsoft did&amp;nbsp; err when they labeled WinFX as .NET3.&amp;nbsp;They should have concatenated a higher number - &amp;nbsp;like .NET5 perhaps.&amp;nbsp; &lt;/p&gt; &lt;p&gt;There&amp;nbsp;are a thousand ways to skin a cat .&amp;nbsp; XAML is first translated to raw C# or VB.NET code during the compilation process.&amp;nbsp; This gives those who are zammel challenged like me, a glimmer of hope that perhaps learning the new mark up can be postponed until a much much later date.&amp;nbsp;&amp;nbsp;That old&amp;nbsp;aphorism&amp;nbsp;may still apply to programming WPF applications.&amp;nbsp; Hope indeed has&amp;nbsp;an uncanny way of&amp;nbsp;manifesting itself&amp;nbsp;even during the bleakest of moments!&lt;/p&gt; &lt;p&gt;If you've been&amp;nbsp;watching the events that have been taking place in the .NET sphere of late, you'll&amp;nbsp;probably notice that there seems to be a language renaissance of sorts.&amp;nbsp; Phython, Ruby, PHP, Smalltalk and other&amp;nbsp;obscure languages, new and old,&amp;nbsp;are in the process or&amp;nbsp;have&amp;nbsp;been successfully ported to .NET.&amp;nbsp; What was once considered a second rate Java&amp;nbsp;VM copycat is fast becoming the United Nations of programming languages. &lt;/p&gt; &lt;p&gt;Among these new .NET languages, Boo is my favorite.&amp;nbsp;&amp;nbsp;It has a very compact syntax, yet it does not compromise anything. It belongs to a new breed of smart programming languages designed specifically&amp;nbsp;for&amp;nbsp;.NET that has been slowly emerging from the underground.&amp;nbsp; The value of Boo becomes evident when you are prototyping something.&amp;nbsp; And that is exactly what most of us will be doing with WPF between now and next year,&amp;nbsp;writing prototype applications to test the waters so to speak.&amp;nbsp; &lt;/p&gt; &lt;p&gt;To start writing WPF applications sans XAML with Boo (or even c#),&amp;nbsp;start by creating a new Boo WinForm application and then delete the dummy WinForm file.&amp;nbsp;&amp;nbsp;Delete&amp;nbsp;all references except Boo.Lang.Useful (you dont need this in c#) &amp;nbsp;and System, then add references to PresentationCore, PresentationFramework and WindowsBase.&amp;nbsp; Add a new Empty Boo File then type the following code like so:&lt;/p&gt; &lt;p&gt;&lt;/p&gt;&lt;pre&gt;namespace Boo.WinFx
import System
import System.Windows
import System.Windows.Navigation

[STAThread]
def Main():
	# create a window
	win = NavigationWindow()
	# create an application
	app = Application()	
	# the first window to be shown becomes the main window
	win.Show()
	# fire the application
	app.Run()	
&lt;/pre&gt;
&lt;p&gt;&lt;a title="Empty NavigationWindow" href="http://www.flickr.com/photos/73686286@N00/251888204/"&gt;&lt;img height="204" alt="Empty NavigationWindow" hspace="0" src="http://static.flickr.com/106/251888204_6f7c4d27f8.jpg" width="318" align="right" border="0"&gt;&lt;/a&gt;Hit F5 to run this barebones WinFx Navigation Application. Notice that we did not enclose the Main function inside a class, yet the program did execute as expected.&amp;nbsp; This is one of the facets of Boo that makes it&amp;nbsp;special.&amp;nbsp; It&amp;nbsp;adopts very well to&amp;nbsp;procedural style of programming.&amp;nbsp; &lt;/p&gt;
&lt;p&gt;There are two types of windows we can use in our applications - the Window and the NavigationWindow. The Window class looks like the old WinForm but that's where their similarities end. The NavigationWindow class inherits from the Window class and extends it with content navigation support.&amp;nbsp; With it we now can create desktop applications that mimic the fuctionality of web applications, without really trying.&amp;nbsp; &lt;/p&gt;
&lt;p&gt;Let's say I would like to build an application that displays a button on the first page. If I click on the button, the app will then navigate to the second page.&amp;nbsp;To do this modify&amp;nbsp;the&amp;nbsp;original code like so:&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;&lt;pre&gt;namespace Boo.WinFx
import System
import System.Windows
import System.Windows.Controls
import System.Windows.Navigation

[STAThread]
def Main():
	# create a window host
	win = NavigationWindow()	
	# create a textblock
	para = TextBlock(Text:"Hello World!!!", FontSize:36)
	para.VerticalAlignment = VerticalAlignment.Center
	para.HorizontalAlignment =HorizontalAlignment.Center	
	# create a button 
	button = Button(Content:"Click Me", Height:30, Width:100)
	# display the textblock when the button is clicked
	button.Click += { win.Navigate(para) }
	# display the button first
	win.Navigate(button)
	# create an application host
	app = Application()
	# show the window
	win.Show()
	# fire the application
	app.Run()
&lt;/pre&gt;
&lt;p&gt;&lt;a title="first page" href="http://www.flickr.com/photos/73686286@N00/252235415/"&gt;&lt;img alt="first page" hspace="0" src="http://static.flickr.com/88/252235415_e3b78d7cbb.jpg" border="0"&gt;&lt;/a&gt; 
&lt;p&gt;&lt;/p&gt;&lt;a title="second page" href="http://www.flickr.com/photos/73686286@N00/252235403/"&gt;&lt;img alt="second page" hspace="0" src="http://static.flickr.com/89/252235403_bc6507985f.jpg" border="0"&gt;&lt;/a&gt;&lt;img src="http://devpinoy.org/aggbug.aspx?PostID=5268" width="1" height="1"&gt;</description><category domain="http://devpinoy.org/blogs/smash/archive/tags/.NET/default.aspx">.NET</category><category domain="http://devpinoy.org/blogs/smash/archive/tags/boo/default.aspx">boo</category><category domain="http://devpinoy.org/blogs/smash/archive/tags/WPF/default.aspx">WPF</category></item></channel></rss>
