<?xml version="1.0" encoding="utf-8"?>
<feed xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" version="0.3" xml:lang="en-us" xmlns="http://purl.org/atom/ns#">
  <title>Richard Davis</title>
  <link rel="alternate" type="text/html" href="http://www.sharplogic.com/blogs/rdavis/" />
  <modified>2008-11-18T12:13:25.8125-08:00</modified>
  <tagline>Software Design Engineer</tagline>
  <generator>newtelligence dasBlog 1.7.5016.2</generator>
  <author>
    <name>Richard Davis</name>
  </author>
  <entry>
    <title>Resetting the Selected Item of a Silverlight 2 ListBox Control</title>
    <link rel="alternate" type="text/html" href="http://www.sharplogic.com/blogs/rdavis/PermaLink,guid,2f5bbfa1-4878-490f-967d-bf00bc04dfde.aspx" />
    <id>http://www.sharplogic.com/blogs/rdavis/PermaLink,guid,2f5bbfa1-4878-490f-967d-bf00bc04dfde.aspx</id>
    <issued>2008-11-18T12:13:25.8125-08:00</issued>
    <modified>2008-11-18T12:13:25.8125-08:00</modified>
    <created>2008-11-18T12:13:25.8125-08:00</created>
    <content type="text/html" mode="xml">
      <body xmlns="http://www.w3.org/1999/xhtml">
        <p>
          <span class="kwrd">
          </span>
        </p>
        <p>
          <span class="kwrd">
          </span>
        </p>
        <p>
      Silverlight version: 2.0.31005.0
   </p>
        <p>
      If you are trying to reset the selected item of a ListBox control using either the
      SelectedItem or SelectedIndex properties, it will not work with the version of Silverlight
      stated above. From what I can glean in the Silverlight forums, this method did at
      one time work (previous release candidate maybe) and is also a known issue that is
      being addressed (for the current version).
   </p>
        <p>
      In the meantime, you can adapt your application to use another existing control or
      custom control, or you could do something like the following:
   </p>
        <p>
          <strong>Option 0</strong>: Reset the selected item or index outside of your SelectionChanged
      event handler. One way to do this is to use a DispatcherTimer. When the ListBox SelectionChanged
      event fires, start the timer. In the Tick handler, stop the timer and perform the
      reset (set SelectedItem to null or SelectedIndex to -1). 
      <br /><em>Drawbacks</em>: this isn’t unexpected, but resetting the selected item is
      reflected by the ListBox UI, so the last selected ListBox item may not be as noticeable
      to the user. If you want to show the last selected item AND enable clicking on the
      same item multiple times in sequence, then see the option below.
   </p>
        <p>
          <strong>Option 1</strong>: You can also reset the selected item without resorting
      to the use of an additional timer. Simply take advantage of the Dispatcher.BeginInvoke
      method like in the following code ('lb' refers to a ListBox instance):
   </p>
        <pre class="csharpcode">Dispatcher.BeginInvoke(<span class="kwrd">new</span> Action(<span class="kwrd">delegate</span>()
   { lb.SelectedItem = <span class="kwrd">null</span>; }));</pre>
        <p>
        </p>
        <style type="text/css">

.csharpcode, .csharpcode pre
{
	font-size: small;
	color: black;
	font-family: consolas, "Courier New", courier, monospace;
	background-color: #ffffff;
	/*white-space: pre;*/
}
.csharpcode pre { margin: 0em; }
.csharpcode .rem { color: #008000; }
.csharpcode .kwrd { color: #0000ff; }
.csharpcode .str { color: #006080; }
.csharpcode .op { color: #0000c0; }
.csharpcode .preproc { color: #cc6633; }
.csharpcode .asp { background-color: #ffff00; }
.csharpcode .html { color: #800000; }
.csharpcode .attr { color: #ff0000; }
.csharpcode .alt 
{
	background-color: #f4f4f4;
	width: 100%;
	margin: 0em;
}
.csharpcode .lnum { color: #606060; }</style>
        <p>
         OR
   </p>
        <pre class="csharpcode">Dispatcher.BeginInvoke(() =&gt; { lb.SelectedItem = <span class="kwrd">null</span>;
   });</pre>
        <style type="text/css">

.csharpcode, .csharpcode pre
{
	font-size: small;
	color: black;
	font-family: consolas, "Courier New", courier, monospace;
	background-color: #ffffff;
	/*white-space: pre;*/
}
.csharpcode pre { margin: 0em; }
.csharpcode .rem { color: #008000; }
.csharpcode .kwrd { color: #0000ff; }
.csharpcode .str { color: #006080; }
.csharpcode .op { color: #0000c0; }
.csharpcode .preproc { color: #cc6633; }
.csharpcode .asp { background-color: #ffff00; }
.csharpcode .html { color: #800000; }
.csharpcode .attr { color: #ff0000; }
.csharpcode .alt 
{
	background-color: #f4f4f4;
	width: 100%;
	margin: 0em;
}
.csharpcode .lnum { color: #606060; }</style>
        <p>
          <strong>Option 2</strong>: Create a custom list box class that inherits from ListBox
      – let’s call it CustomListBox. Override the GetContainerForItemOverride
      method to return a custom list box item class (CustomListBoxItem) rather than the
      default ListBoxItem instance. Create a new public event called CustomSelectionChanged
      which will serve as the replacement for SelectionChanged. 
   </p>
        <pre class="csharpcode">
          <span class="kwrd">public</span>
          <span class="kwrd">class</span> CustomListBox
   : ListBox { <span class="rem">//fired every time a list box item is clicked</span><span class="kwrd">public</span><span class="kwrd">event</span> SelectionChangedEventHandler
   CustomSelectionChanged; <span class="kwrd">protected</span><span class="kwrd">override</span> DependencyObject
   GetContainerForItemOverride() { CustomListBoxItem item = <span class="kwrd">new</span> CustomListBoxItem(<span class="kwrd">this</span>); <span class="kwrd">if</span> (<span class="kwrd">base</span>.ItemContainerStyle
   != <span class="kwrd">null</span>) { item.Style = <span class="kwrd">base</span>.ItemContainerStyle;
   } <span class="kwrd">return</span> item; } <span class="kwrd">public</span><span class="kwrd">void</span> OnCustomSelectionChanged(CustomListBoxItem
   item) { List&lt;CustomListBoxItem&gt; addedItems = 
   <br /><span class="kwrd">new</span> List&lt;CustomListBoxItem&gt;(); addedItems.Add(item);
   SelectionChangedEventHandler handler = CustomSelectionChanged; <span class="kwrd">if</span> (handler
   != <span class="kwrd">null</span>) { handler(<span class="kwrd">this</span>, <span class="kwrd">new</span> SelectionChangedEventArgs(<br /><span class="kwrd">new</span> List&lt;CustomListBoxItem&gt;(), addedItems)); } } }</pre>
        <style type="text/css">
















.csharpcode, .csharpcode pre
{
	font-size: small;
	color: black;
	font-family: consolas, "Courier New", courier, monospace;
	background-color: #ffffff;
	/*white-space: pre;*/
}
.csharpcode pre { margin: 0em; }
.csharpcode .rem { color: #008000; }
.csharpcode .kwrd { color: #0000ff; }
.csharpcode .str { color: #006080; }
.csharpcode .op { color: #0000c0; }
.csharpcode .preproc { color: #cc6633; }
.csharpcode .asp { background-color: #ffff00; }
.csharpcode .html { color: #800000; }
.csharpcode .attr { color: #ff0000; }
.csharpcode .alt 
{
	background-color: #f4f4f4;
	width: 100%;
	margin: 0em;
}
.csharpcode .lnum { color: #606060; }</style>
        <p>
      In CustomListBoxItem, which should inherit from ListBoxItem, create a constructor
      that takes a CustomListBox instance as a parameter and stores is for later use. Finally,
      override the OnMouseLeftButtonDown method and fire the CustomSelectionChanged event
      of the containing CustomListBox.
   </p>
        <pre class="csharpcode">
          <span class="kwrd">public</span>
          <span class="kwrd">class</span> CustomListBoxItem
   : ListBoxItem { CustomListBox _customListBoxContainer; <span class="rem">// Needed
   to avoid error in case of instantiation in XAML. If </span><span class="rem">// CustomListBoxItems
   are added in XAML directly, </span><span class="rem">// CustomListBox will act like
   a normal ListBox and only allow </span><span class="rem">// each item to be selected
   once.</span><span class="kwrd">public</span> CustomListBoxItem() { } <span class="kwrd">public</span> CustomListBoxItem(CustomListBox
   customListBox) { <span class="kwrd">this</span>._customListBoxContainer = customListBox;
   } <span class="kwrd">protected</span><span class="kwrd">override</span><span class="kwrd">void</span> OnMouseLeftButtonDown(MouseButtonEventArgs
   e) { <span class="kwrd">base</span>.OnMouseLeftButtonDown(e); <span class="kwrd">if</span> (<span class="kwrd">this</span>._customListBoxContainer
   != <span class="kwrd">null</span>) { <span class="kwrd">this</span>._customListBoxContainer.OnCustomSelectionChanged(<span class="kwrd">this</span>);
   } } }</pre>
        <p>
      Download example: <a href="http://www.sharplogic.com/blogs/rdavis/content/binary/ResetListBoxExample.zip" target="_blank">ResetListBoxExample.zip</a></p>
        <img width="0" height="0" src="http://www.sharplogic.com/blogs/rdavis/aggbug.ashx?id=2f5bbfa1-4878-490f-967d-bf00bc04dfde" />
      </body>
    </content>
  </entry>
  <entry>
    <title>Open folders in a command window quickly in Vista </title>
    <link rel="alternate" type="text/html" href="http://www.sharplogic.com/blogs/rdavis/PermaLink,guid,a81d497d-28e3-406d-a522-8d5b96dd8882.aspx" />
    <id>http://www.sharplogic.com/blogs/rdavis/PermaLink,guid,a81d497d-28e3-406d-a522-8d5b96dd8882.aspx</id>
    <issued>2006-11-29T16:27:31.109375-08:00</issued>
    <modified>2006-11-29T16:27:31.109375-08:00</modified>
    <created>2006-11-29T16:27:31.109375-08:00</created>
    <content type="text/html" mode="xml">
      <body xmlns="http://www.w3.org/1999/xhtml">There is a nice shortcut in Vista that
   allows you to open a command window with the path set to a specific folder at startup.
   This can be done by holding Shift and right-clicking on a folder in Explorer. When
   the context menu appears, you can select "Open Command Window Here". Alternatively,
   you could use the Application key + Shift followed by the 'W' key. <img border="0" src="http://www.sharplogic.com/blogs/rdavis/content/binary/ss.png" /> On
   a related note, you can no longer drag and drop a folder from Explorer into a command
   window in order to paste the path information.<img width="0" height="0" src="http://www.sharplogic.com/blogs/rdavis/aggbug.ashx?id=a81d497d-28e3-406d-a522-8d5b96dd8882" /></body>
    </content>
  </entry>
  <entry>
    <title>Web time machine!</title>
    <link rel="alternate" type="text/html" href="http://www.sharplogic.com/blogs/rdavis/PermaLink,guid,83f92e7d-23bb-4cc9-8d4e-5eec523fa5e8.aspx" />
    <id>http://www.sharplogic.com/blogs/rdavis/PermaLink,guid,83f92e7d-23bb-4cc9-8d4e-5eec523fa5e8.aspx</id>
    <issued>2006-06-23T00:18:50.890625-07:00</issued>
    <modified>2006-06-23T00:18:50.890625-07:00</modified>
    <created>2006-06-23T00:18:50.890625-07:00</created>
    <content type="text/html" mode="xml">
      <body xmlns="http://www.w3.org/1999/xhtml">
        <p>
      At SharpLogic Software, we have a wide variety of backgrounds as well as talents.
      Since I came aboard in early 2005, I have had the opportunity to interface with a
      number of different characters. One side-effect that happens after meeting and working
      with people who are truly passionate about technology and gifted with their work is
      that you realize just how much YOU have to learn. Of course, there are skills which
      are not easily learned - and are truly gifts some are born with. For me, and many
      others who say something like "I apologize for the drawing, I am not an artist..."
      during a presentation, no amount of practice will render me with the ability to create
      a beautiful Web page. I might be able to learn a thing or two about layout and read
      about user interface design, but I will still probably pick neon green text on a black
      background with an orange border. Luckily for us we have people on staff who effortlessly
      bridge the gap between artistic design and technical functionality.
   </p>
        <p>
      The reason that I bring this topic up is because being around these Web geniuses has
      made me think back to years gone by when I learned a little HTML and for some reason
      thought it wise to create my own homepage. I jokingly thought to myself "I sure hope
      that nobody decided to archive that content from the Web past". Tonight I did a quick
      search for such a thing and came across <a href="http://archive.org">http://archive.org</a> which,
      among other things, allows you to search their archived index of some Web sites from
      the past. This includes domains that you may have owned at one point and are now in
      the hands of someone else. It is not a complete archive, but it sure is fun looking
      back at old content many Web developers may have thought was gone. It is also neat
      to simply see the evolution of a site over time. Take a spin and see if you can find
      any interesting archived pages. 
   </p>
        <p>
      Check out an example from Microsoft from October 1996 at <a href="http://web.archive.org/web/19961022175331/http://www.microsoft.com/">http://web.archive.org/web/19961022175331/http://www.microsoft.com/</a></p>
        <p>
      MSN.com from 1996, <a href="http://web.archive.org/web/19961025231757/http://msn.com/">http://web.archive.org/web/19961025231757/http://msn.com/</a></p>
        <p>
      Google.com from 1998, <a href="http://web.archive.org/web/19981202230410/http://www.google.com/">http://web.archive.org/web/19981202230410/http://www.google.com/</a></p>
        <p>
      Only a few sites that I have tried are actually blocked from being searched. I do
      not know if this is an opt-out mechanism offered to site owners or something else
      entirely.
   </p>
        <img width="0" height="0" src="http://www.sharplogic.com/blogs/rdavis/aggbug.ashx?id=83f92e7d-23bb-4cc9-8d4e-5eec523fa5e8" />
      </body>
    </content>
  </entry>
  <entry>
    <title>Funniest Algorithm Names</title>
    <link rel="alternate" type="text/html" href="http://www.sharplogic.com/blogs/rdavis/PermaLink,guid,4b7e4a39-16aa-478e-bf22-4998a52edf37.aspx" />
    <id>http://www.sharplogic.com/blogs/rdavis/PermaLink,guid,4b7e4a39-16aa-478e-bf22-4998a52edf37.aspx</id>
    <issued>2005-09-28T02:29:45.2565417-07:00</issued>
    <modified>2005-09-28T02:29:45.2565417-07:00</modified>
    <created>2005-09-28T02:29:45.2565417-07:00</created>
    <content type="text/html" mode="xml">
      <body xmlns="http://www.w3.org/1999/xhtml">
        <p>
      So I was looking at the list of algorithms page on Wikipedia, located at <a href="http://en.wikipedia.org/wiki/List_of_algorithms">http://en.wikipedia.org/wiki/List_of_algorithms</a>,
      the other day when I noticed a few funny sounding ones:
   </p>
        <p>
          <em>Blum Blum Shub</em> – a pseudorandom number generator (named after the creators)<br /><em>Bogosort</em> – sort that generates random permutations until it finds “the one”<br /><em>Blowfish</em> – type of block cipher<br /><em>Doomsday</em> – calculates the day of the week of a given date (apparently each
      year has a doomsday, the day of the week on which the last day of February falls)
   </p>
        <p>
      Leave a comment if you know of others :)
   </p>
        <img width="0" height="0" src="http://www.sharplogic.com/blogs/rdavis/aggbug.ashx?id=4b7e4a39-16aa-478e-bf22-4998a52edf37" />
      </body>
    </content>
  </entry>
  <entry>
    <title>SharpLogic Summer BBQ</title>
    <link rel="alternate" type="text/html" href="http://www.sharplogic.com/blogs/rdavis/PermaLink,guid,a40de9be-2f44-4c45-b7f5-79e29ce3cd6e.aspx" />
    <id>http://www.sharplogic.com/blogs/rdavis/PermaLink,guid,a40de9be-2f44-4c45-b7f5-79e29ce3cd6e.aspx</id>
    <issued>2005-09-28T01:40:03.2900485-07:00</issued>
    <modified>2005-09-28T01:40:03.2900485-07:00</modified>
    <created>2005-09-28T01:40:03.2900485-07:00</created>
    <content type="text/html" mode="xml">
      <body xmlns="http://www.w3.org/1999/xhtml">
        <p>
      It has actually been a couple of months since we all got together for some hamburgers
      and it turns out that some pictures were taken, unbeknownst to me at the time, while
      we played basketball at SharpLogic Arena.
   </p>
        <p>
      I am actually quite proud of the first picture because I am able to successfully demonstrate
      my remarkable ability of holding a basketball over my head.  Notice that both
      Ezju and Chris are fascinated by my feat.
   </p>
        <p>
          <img src="http://www.sharplogic.com/blogs/rdavis/content/binary/richard_lifting_bball.jpg" border="0" />
        </p>
        <p>
      After a long awkward moment of holding the ball over my head I decided that I should
      move closer to the basket for a higher percentage shot.  Closer = higher percentage
      right?
   </p>
        <p>
          <img src="http://www.sharplogic.com/blogs/rdavis/content/binary/ezju_explains_bball_to_richard.jpg" border="0" />
        </p>
        <p>
      So I moved closer to the basket and boldly lifted the basketball over my head once
      again.  Unfortunately, I quickly ran into another problem, that being the backboard. 
      You see, the basket is read-only from this side.  Thanks to Ezju for pointing
      that out to me.
   </p>
        <p>
      The highlight of the day came when Ed showed off his force powers as he slowly moved
      a levitating basketball towards the hoop without lifting a finger.  Notice that
      Ezju is there to help supervise the action once again.
   </p>
        <p>
          <img src="http://www.sharplogic.com/blogs/rdavis/content/binary/ed_demonstrates_using_the_force.jpg" border="0" />
        </p>
        <img width="0" height="0" src="http://www.sharplogic.com/blogs/rdavis/aggbug.ashx?id=a40de9be-2f44-4c45-b7f5-79e29ce3cd6e" />
      </body>
    </content>
  </entry>
  <entry>
    <title>Amusing Exception Message</title>
    <link rel="alternate" type="text/html" href="http://www.sharplogic.com/blogs/rdavis/PermaLink,guid,86068904-f7f7-45ec-b1e1-b4f0d5a85647.aspx" />
    <id>http://www.sharplogic.com/blogs/rdavis/PermaLink,guid,86068904-f7f7-45ec-b1e1-b4f0d5a85647.aspx</id>
    <issued>2005-09-28T00:11:15.3159452-07:00</issued>
    <modified>2005-09-28T00:11:15.3159452-07:00</modified>
    <created>2005-09-28T00:11:15.3159452-07:00</created>
    <content type="text/html" mode="xml">
      <body xmlns="http://www.w3.org/1999/xhtml">
        <p>
      I was recently working with GDI+ drawing when I found the need to modify a Pen's Width
      property.  I often use the Pens class as a matter of convenience so my first
      thought was to simply write the following:
   </p>
        <p>
      Pens.Yellow.Width = 3;
   </p>
        <p>
      However, that did not work too well as I was greeted with the exception "You may not
      change this Pen because it does not belong to you."  When I read the message
      I immediately realized that I had made a mistake, but the wording of the exception
      message also made me laugh a little.  It sounds like the Drawing namespace is
      a little kid that doesn't want me to play with its toys, although in that case it
      would probably just say "Mine!"
   </p>
        <p>
          <img src="http://www.sharplogic.com/blogs/rdavis/content/binary/funny_exception.png" border="0" />
        </p>
        <p>
      In case you are wondering, the Pens class houses a number of static properties representing
      a number of colors, including Yellow.  The static Yellow property will
      create a new immutable Pen object with width 1 when you first use it and then store
      it in a hash table for future use.  Future calls to Pens.Yellow will get the
      same Pen object that was previously stored in the hash table.  This is done because
      GDI Pens are a limited resource that needs to be conserved.
   </p>
        <p>
       
   </p>
        <img width="0" height="0" src="http://www.sharplogic.com/blogs/rdavis/aggbug.ashx?id=86068904-f7f7-45ec-b1e1-b4f0d5a85647" />
      </body>
    </content>
  </entry>
  <entry>
    <title>Return Me.PortlandCodeCampExperience</title>
    <link rel="alternate" type="text/html" href="http://www.sharplogic.com/blogs/rdavis/PermaLink,guid,83ee7e7c-35e7-4e3f-8326-eb28cf202c0a.aspx" />
    <id>http://www.sharplogic.com/blogs/rdavis/PermaLink,guid,83ee7e7c-35e7-4e3f-8326-eb28cf202c0a.aspx</id>
    <issued>2005-07-27T02:03:19.4162712-07:00</issued>
    <modified>2005-07-27T02:03:19.4162712-07:00</modified>
    <created>2005-07-27T02:03:19.4162712-07:00</created>
    <content type="text/html" mode="xml">
      <body xmlns="http://www.w3.org/1999/xhtml">
        <p>
      Portland Code Camp v1.0 was unleashed July 23 and 24 and I am happy that I was able
      to attend.  I went to a number of sessions covering the following topics:
   </p>
        <p>
      •     Visual Studio Tools for Office (VS 2005)<br />
      •     Intercepting API Calls<br />
      •     ASP.NET 2.0 Web Parts<br />
      •     SQL 2005 Development<br />
      •     .NET Windows Forms Tips &amp; Tricks<br />
      •     Extensible .NET Applications<br />
      •     ASP.NET Tips &amp; Tricks<br />
      •     Forensic Development<br />
      •     Versions Gone Wild
   </p>
        <p>
      Proof I was there (not that anyone really cares):
   </p>
        <p>
          <img src="http://www.sharplogic.com/blogs/rdavis/content/binary/rd_in_session.jpg" border="0" />
        </p>
        <p>
      Now admittedly some of the content was over my head, such as in the Intercepting API
      Calls session, but that does not mean that I did not take anything away from it. 
      When security experts or DB administrators start talking about their specialties and
      glossing over many of the prerequisites, it is not hard for me to get a little lost. 
      This session could have used more demos, but I understand that the content was in
      the nitpicky details which take a lot of time to actually show.
   </p>
        <p>
      Tips and Tricks sessions are always nice because you can cram so much information
      into a single hour time slot.  These types of sessions are good because they
      present seeds of information that you can take with you and use later.  Details
      are not as necessary here, but general ideas on where to start with a given problem
      can be very valuable.
   </p>
        <p>
      The Extensible .NET Application session was essentially a case study which focused
      on a specific solution.  While it would be nice if the entire range of possible
      design choices could be covered in more detail, I realize that only so much can happen
      in one hour.  It was nice to get into the details of the code and listen to some
      of the gotchas that were found during development of a particular solution.
   </p>
        <p>
      Braindump for other Code Camp related thoughts: donuts, lots of donuts… Seattle to
      Portland traffic and the reverse = System.OverflowException… Subway for breakfast,
      lunch, and dinner… Portland has enough bridges… 
      <br /></p>
        <img width="0" height="0" src="http://www.sharplogic.com/blogs/rdavis/aggbug.ashx?id=83ee7e7c-35e7-4e3f-8326-eb28cf202c0a" />
      </body>
    </content>
  </entry>
  <entry>
    <title>Napoleon Dynamite and XXX Stole My Thunder</title>
    <link rel="alternate" type="text/html" href="http://www.sharplogic.com/blogs/rdavis/PermaLink,guid,c2958a2a-f69f-4a44-8bea-18aa694c92b1.aspx" />
    <id>http://www.sharplogic.com/blogs/rdavis/PermaLink,guid,c2958a2a-f69f-4a44-8bea-18aa694c92b1.aspx</id>
    <issued>2005-07-21T01:18:04.2839399-07:00</issued>
    <modified>2005-07-21T01:34:59.8664582-07:00</modified>
    <created>2005-07-21T01:18:04.2839399-07:00</created>
    <content type="text/html" mode="xml">
      <body xmlns="http://www.w3.org/1999/xhtml">
        <p>
      Have you ever felt like you had a good thing going before someone famous decided to
      give it an entirely new meaning altogether?  Believe it or not, it has happened
      to me but I will not be appearing on Oprah anytime soon.
   </p>
        <p>
      Here is the story.  A few years ago I received a nice orange t-shirt from a family
      member as a gift, and it said something like “XXX Workwear” on it.  So I happily
      wore it around for a few months, and then Mr. Diesel starred in a movie called XXX. 
      Needless to say, everybody started to make comments when I wore the shirt, which isn’t
      bad or anything, but I felt the obligation to tell people, “I HAD THE SHIRT BEFORE
      XXX EXISTED!”
   </p>
        <p>
      More recently I had a white custom t-shirt made that has black rings around the sleeves
      and collar and says “I Support Rabid Llamas” on the front.  My design even used
      a nice red font to stand out.  Now those of you familiar with the movie Napoleon
      Dynamite will know about the “Vote for Pedro” t-shirt.  Guess what?  I made
      the shirt before the movie was out!  When I wear my shirt I am guessing that
      people think I am copying the movie or something, which is far from the truth.
   </p>
        <p>
      I am kind of amazed that this situation has happened to me twice in the last few years,
      and even more surprised that it has been over a t-shirt.  Oh well, let those
      darn movies ruin the meaning of my wardrobe.  At least we have all learned something
      from the movie XXX – you can deflect a missile with a serving platter!
   </p>
        <img width="0" height="0" src="http://www.sharplogic.com/blogs/rdavis/aggbug.ashx?id=c2958a2a-f69f-4a44-8bea-18aa694c92b1" />
      </body>
    </content>
  </entry>
  <entry>
    <title>Funniest .NET languages</title>
    <link rel="alternate" type="text/html" href="http://www.sharplogic.com/blogs/rdavis/PermaLink,guid,ac3126a9-d360-4231-ba9f-009060ab7bc1.aspx" />
    <id>http://www.sharplogic.com/blogs/rdavis/PermaLink,guid,ac3126a9-d360-4231-ba9f-009060ab7bc1.aspx</id>
    <issued>2005-07-21T00:30:01.2510791-07:00</issued>
    <modified>2005-07-21T00:30:01.2510791-07:00</modified>
    <created>2005-07-21T00:30:01.2510791-07:00</created>
    <content type="text/html" mode="xml">
      <body xmlns="http://www.w3.org/1999/xhtml">
        <p>
      What are the funniest .NET language names out there?  Here are a few that tickled
      my funny bone.  By the way, I ran them by my wife and she authenticated their
      funniness.  While I do openly poke fun at the names, it is all in good fun. 
      No harm came to the languages used in the making of this posting.
   </p>
        <p>
      Boo<br />
      Common Larceny<br />
      Objective Caml<br />
      Hotdog<br />
      Tachy<br />
      TickleSharp
   </p>
        <img width="0" height="0" src="http://www.sharplogic.com/blogs/rdavis/aggbug.ashx?id=ac3126a9-d360-4231-ba9f-009060ab7bc1" />
      </body>
    </content>
  </entry>
  <entry>
    <title>Visualization Tools for Computer Science Education</title>
    <link rel="alternate" type="text/html" href="http://www.sharplogic.com/blogs/rdavis/PermaLink,guid,458b37ef-5c99-4aaf-8138-5fa300afb464.aspx" />
    <id>http://www.sharplogic.com/blogs/rdavis/PermaLink,guid,458b37ef-5c99-4aaf-8138-5fa300afb464.aspx</id>
    <issued>2005-06-28T03:16:14.7621065-07:00</issued>
    <modified>2005-07-20T23:42:50.4973104-07:00</modified>
    <created>2005-06-28T03:16:14.7621065-07:00</created>
    <content type="text/html" mode="xml">
      <body xmlns="http://www.w3.org/1999/xhtml">
        <p>
      One of my favorite subjects within the realm of Computer Science topics is computer
      graphics and visualization.  Part of the draw, especially early on in my school
      career, was the instant gratification that could be found in implementing graphics
      code.  You get to directly see the results of your labor plus you can easily
      share it with others who do not understand the implementation details.
   </p>
        <p>
      There are basically three types of learning methods – auditory, visual, and hands-on. 
      Of course, most people use a combination of all three throughout their life. 
      I am not sure if I am more hands-on or visual, but I am certain that I do not learn
      best through auditory means.  Therefore, unless I am somewhat familiar with a
      topic to begin with, lectures seem like a waste of time to me, at least the prototypical
      theory-only college lectures.  I take notes, but I have no chance of “getting
      it” until I sit down and have some hands-on time with the material.
   </p>
        <p>
      I think that students could benefit greatly from tools that help visualize core computer
      science topics such as search algorithms, recursion, data structures, etc.  Unfortunately,
      for whatever reason, my instructors did not know that these types of applications
      existed, and neither did I until recently.  There are some very sophisticated
      scientific and data visualization tools out there, but I am currently just referring
      to fairly simple instructional tools with good interfaces.
   </p>
        <p>
      Here is a link to a J# application for visualizing sorting algorithms, recursion,
      simple image viewing, and an oscilloscope simulation.  It allows you to even
      test your own algorithm implementations and see how they perform (Visual J# .NET Product
      Team, Microsoft).
   </p>
        <p>
          <a href="https://www.mainfunction.com/DotNetInAction/Technologies/display.aspx?ID=2710&amp;TypeID=2">https://www.mainfunction.com/DotNetInAction/Technologies/display.aspx?ID=2710&amp;TypeID=2</a>
        </p>
        <p>
      The next link has some Java applications that help visualize automata and formal languages
      (Susan Rodger, Duke University).
   </p>
        <p>
          <a href="http://www.cs.duke.edu/~rodger/tools/tools.html">http://www.cs.duke.edu/~rodger/tools/tools.html</a>
        </p>
        <p>
      Here is a well written paper titled “Helping Learners Visualize and Comprehend Algorithms”
      by Hansen, Narayanan, and Schrimpsher.
   </p>
        <p>
          <a href="http://imej.wfu.edu/articles/2000/1/02/index.asp">http://imej.wfu.edu/articles/2000/1/02/index.asp</a>
        </p>
        <p>
      I am sure that there are more visualization tools out there.  So are these tools
      being used at the high school or even undergraduate college level?  Aside from
      the elected computer graphics classes that I took in college, I do not remember having
      an instructor utilize visualization software in any way.
   </p>
        <img width="0" height="0" src="http://www.sharplogic.com/blogs/rdavis/aggbug.ashx?id=458b37ef-5c99-4aaf-8138-5fa300afb464" />
      </body>
    </content>
  </entry>
  <entry>
    <title>.zip file problems</title>
    <link rel="alternate" type="text/html" href="http://www.sharplogic.com/blogs/rdavis/PermaLink,guid,0ebed837-2f23-405b-89a4-d02df839901e.aspx" />
    <id>http://www.sharplogic.com/blogs/rdavis/PermaLink,guid,0ebed837-2f23-405b-89a4-d02df839901e.aspx</id>
    <issued>2005-05-28T02:26:22.4508607-07:00</issued>
    <modified>2005-07-20T23:44:17.7322437-07:00</modified>
    <created>2005-05-28T02:26:22.4508607-07:00</created>
    <content type="text/html" mode="xml">
      <body xmlns="http://www.w3.org/1999/xhtml">
        <p>
      There seems to be a few different species of .zip file out there in the wild now. 
      I have run into problems decompressing some .zip archives recently and decided I should
      look into the problem further.  According to one article from the September 2003
      PCWorld, <a href="http://www.pcworld.com/news/article/0,aid,111772,00.asp">http://www.pcworld.com/news/article/0,aid,111772,00.asp</a>,
      the problem with incompatibility typically comes from proprietary encryption schemes
      being used.  Even implementations of the AES encryption scheme can vary by .zip
      software package.<br />
       <br />
      Unfortunately, I have run into situations where I get a .zip file from someone else
      and the Windows .zip software states that there is an error with the file.  The
      problem is not encryption.  I have not found the root problem yet as using another
      third-party tool is usually successful at unzipping problem files.  Next time
      I run into the problem and the file is not multiple gigabytes in size, I will set
      it aside for a more detailed investigation.
   </p>
        <p>
      I typically use the .zip implementation that is provided by Windows XP for convenience
      and compatibility reasons.  Since I rarely have a need to encrypt files then
      this simple implementation is just fine.  The XP .zip implementation uses compression
      method “deflated” from the .zip specification and “normal” for the compression sub-type. 
      These options should make XP .zip files compatible with all other .zip software, but
      at the same time I realize they are not all that modern or optimal.
   </p>
        <p>
      Another interesting thing that I learned while skimming the specification for the
      .zip format was that 4GB is the upper limit for file sizes.  Definitely something
      to keep in mind when working with large files like Virtual PC images.<br /></p>
        <img width="0" height="0" src="http://www.sharplogic.com/blogs/rdavis/aggbug.ashx?id=0ebed837-2f23-405b-89a4-d02df839901e" />
      </body>
    </content>
  </entry>
  <entry>
    <title>Rebates - a hideously complex marketing scheme that, although quite ingenious, sucks for consumers.</title>
    <link rel="alternate" type="text/html" href="http://www.sharplogic.com/blogs/rdavis/PermaLink,guid,794c164d-a2d3-44b8-adeb-fbb2cd921505.aspx" />
    <id>http://www.sharplogic.com/blogs/rdavis/PermaLink,guid,794c164d-a2d3-44b8-adeb-fbb2cd921505.aspx</id>
    <issued>2005-05-10T10:56:05.0273078-07:00</issued>
    <modified>2005-07-20T23:44:49.2168202-07:00</modified>
    <created>2005-05-10T10:56:05.0273078-07:00</created>
    <content type="text/html" mode="xml">
      <body xmlns="http://www.w3.org/1999/xhtml">
        <p>
      The word “rebate” invokes a variety of primal emotions, including fear, anger, hunger,
      and an itchy ancient cortex.  It can also lead to a number of physical ailments
      including hair loss, old age, arthritis, paper cuts, and sometimes even lockjaw. 
      While the cure may be many years away, support groups may be able to help.  If
      you know of any, let me know.
   </p>
        <p>
      I think that many consumers will buy a product over another similar one because of
      a rebate offer.  Even consumers that have been burned by the rebate system before
      will repeat their behavior, hoping that this time they will win the lottery. 
      They think that maybe there have been enough complaints by consumer groups since their
      last rebate attempt that it will be a smoother process now.  I have received
      a rebate before, but it did require a few phone calls, emails, and general fuss to
      get it. 
   </p>
        <p>
      For me, there may be a certain monetary threshold to cross which forces me to take
      action like many others.  I no longer buy products just because they have a small
      rebate attached to them.  I know that it is not worth my time or aggravation. 
      The sad part is that I am still slightly aggravated because I know that the business
      marketing teams are winning.  Instead of playing the rebate game to save money,
      I think I will start a coupon collection.  Just by themselves they are worth
      something like 1/1000 of a cent.
   </p>
        <p>
      My most recent rebate redemption attempt starts at Staples.  I purchased a wireless
      USB Ethernet adapter for my laptop and gathered all of the required rebate paperwork. 
      Now, at this point, I was not sure if I was going to go through the trouble of filling
      everything out and sending it in.  However, they now have this new rebate submission
      process code-named Staples Easy Rebates where you can submit for rebates online with
      no paperwork or UPC required for mail in.  The submission process was very easy,
      except for the fact that it took three attempts to enter my information.  After
      my submission I received this prompt email notice:
   </p>
        <p>
          <br />
          <em>Thursday, March 31, 2005 2:25 PM<br />
      Subject: We got it. And soon you will get it back.<br />
      Thank you for submitting your rebate request(s) through Staples Easy Rebates. 
      <br />
      We have received rebate information for the following product(s):<br />
         NETGEAR 54MBPS USB 2.0 ADAPTER<br />
         We will begin processing your request(s) shortly.</em>
        </p>
        <p>
          <br />
      Much to my surprise I received this email next:
   </p>
        <p>
          <br />
          <em>Wednesday, April 13, 2005 6:42 PM<br />
      Subject: The check is in the mail! (Really.)<br />
      Thank you for submitting your rebate request(s) through Staples Easy Rebates. 
      <br />
      We have processed your rebate information for the following product(s):<br />
         NETGEAR WG111 54 MBPS WIRELESS USB ADAPTER<br />
      We have mailed out your rebate, so check your mailbox!  You should receive it
      shortly.  
      <br />
      Thank you again for shopping Staples and for using Easy Rebates!</em>
        </p>
        <p>
          <br />
      They must have some very excitable people writing their automated emails!  I
      especially like the way they worded their subject line in their last email to me. 
      Unfortunately, I have not received the rebate check that is currently circulating
      in the mail system, desperately seeking to get to Washington, hoping dearly to find
      Redmond, itching to locate my street, and we will see if it ever arrives in my mailbox.
   </p>
        <img width="0" height="0" src="http://www.sharplogic.com/blogs/rdavis/aggbug.ashx?id=794c164d-a2d3-44b8-adeb-fbb2cd921505" />
      </body>
    </content>
  </entry>
</feed>