<?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" xml:lang="en-us" xmlns="http://www.w3.org/2005/Atom">
  <title>31a2ba2a-b718-11dc-8314-0800200c9a66</title>
  <link rel="alternate" type="text/html" href="http://www.31a2ba2a-b718-11dc-8314-0800200c9a66.com/" />
  <link rel="self" href="http://www.31a2ba2a-b718-11dc-8314-0800200c9a66.com/SyndicationService.asmx/GetAtom" />
  <icon>favicon.ico</icon>
  <updated>2008-06-30T09:41:34.8656256-07:00</updated>
  <author>
    <name>Your Name Here</name>
  </author>
  <subtitle>newtelligence powered</subtitle>
  <id>http://www.31a2ba2a-b718-11dc-8314-0800200c9a66.com/</id>
  <generator uri="http://www.dasblog.net" version="2.0.7180.0">DasBlog</generator>
  <entry>
    <title>Blackberry thows exception</title>
    <link rel="alternate" type="text/html" href="http://www.31a2ba2a-b718-11dc-8314-0800200c9a66.com/2008/06/30/BlackberryThowsException.aspx" />
    <id>http://www.31a2ba2a-b718-11dc-8314-0800200c9a66.com/PermaLink,guid,3da348b2-3abc-4af2-a95c-4c4db1780ce5.aspx</id>
    <published>2008-06-30T09:41:13-07:00</published>
    <updated>2008-06-30T09:40:27.2388944-07:00</updated>
    <category term="Dina" label="Dina" scheme="http://www.31a2ba2a-b718-11dc-8314-0800200c9a66.com/CategoryView,category,Dina.aspx" />
    <content type="xhtml">
      <div xmlns="http://www.w3.org/1999/xhtml">
        <p>
My blackberry just threw an exception. The consumer in me thinks oh, $%^@#$. The programmer
in me thinks that's so cool, I wonder what did it. A hard boot got the thing going
again. 
</p>
        <img width="0" height="0" src="http://dina.berryintl.com/Blog/cptrk.ashx?id=0cf7f114-7113-4acb-a55c-45f7a6cbfe48" />
        <img width="0" height="0" src="http://www.31a2ba2a-b718-11dc-8314-0800200c9a66.com/aggbug.ashx?id=3da348b2-3abc-4af2-a95c-4c4db1780ce5" />
      </div>
    </content>
  </entry>
  <entry>
    <title>User Login, Create User, Send Password close to done</title>
    <link rel="alternate" type="text/html" href="http://www.31a2ba2a-b718-11dc-8314-0800200c9a66.com/2008/06/25/UserLoginCreateUserSendPasswordCloseToDone.aspx" />
    <id>http://www.31a2ba2a-b718-11dc-8314-0800200c9a66.com/PermaLink,guid,dbeb3f9e-08df-4e92-9fa2-63c4e1838b47.aspx</id>
    <published>2008-06-24T20:39:38-07:00</published>
    <updated>2008-06-30T09:41:34.8656256-07:00</updated>
    <category term="Dina" label="Dina" scheme="http://www.31a2ba2a-b718-11dc-8314-0800200c9a66.com/CategoryView,category,Dina.aspx" />
    <category term="Dina's Pet Project" label="Dina's Pet Project" scheme="http://www.31a2ba2a-b718-11dc-8314-0800200c9a66.com/CategoryView,category,Dina's%2BPet%2BProject.aspx" />
    <content type="xhtml">
      <div xmlns="http://www.w3.org/1999/xhtml">
        <p>
The basics for the login pages are done. A few more tweaks and that will be done. 
</p>
        <p>
It might seem like I take forever but in truth, I don't have many hours a week to
give to this pet project right now. I hope to have more time this fall.
</p>
        <p>
 
</p>
        <img height="0" src="http://dina.berryintl.com/Blog/cptrk.ashx?id=48f27214-3df1-47da-8871-2ba16b4916b8" width="0" />
        <img width="0" height="0" src="http://www.31a2ba2a-b718-11dc-8314-0800200c9a66.com/aggbug.ashx?id=dbeb3f9e-08df-4e92-9fa2-63c4e1838b47" />
      </div>
    </content>
  </entry>
  <entry>
    <title>The Dark Side of Extension Methods</title>
    <link rel="alternate" type="text/html" href="http://www.31a2ba2a-b718-11dc-8314-0800200c9a66.com/2008/06/06/TheDarkSideOfExtensionMethods.aspx" />
    <id>http://www.31a2ba2a-b718-11dc-8314-0800200c9a66.com/PermaLink,guid,fde4b553-b25e-42aa-b519-b03819de3c6b.aspx</id>
    <published>2008-06-05T19:19:17.32-07:00</published>
    <updated>2008-06-05T19:23:40.5930364-07:00</updated>
    <category term="C#" label="C#" scheme="http://www.31a2ba2a-b718-11dc-8314-0800200c9a66.com/CategoryView,category,C%23.aspx" />
    <category term="Will" label="Will" scheme="http://www.31a2ba2a-b718-11dc-8314-0800200c9a66.com/CategoryView,category,Will.aspx" />
    <content type="xhtml">
      <div xmlns="http://www.w3.org/1999/xhtml">
        <p>
In my quest to find a suitable generic update method for a generic LINQ Data
Access class I have found a decent amount of code and even more theories (sans
code).  Some good, some verbose, and a lot bad.  It seems that Extension
Methods are a fan favorite for just about everything nowadays and I wasn't suprised
to see Extension Methods being used for LINQ to SQL updates.
</p>
        <p>
In reading about Extension Methods I have heard good and bad feedback.  The good
usually involves the convenience of bypassing a utility class and the bad involving
code readability / maintability.  Forgive me for I am the William Hung of LINQ
as I have had no formal training in this arena, but IMHO Extension Methods are a pain-in-the-ass
when ExtensionMethodA returns the result of ExtensionMethodB which depends on
the output of ExtensionMethodC which ..... Here is an example of what I
am talking about in pseudo-code:
</p>
        <code>
          <p>
            <font color="#0000ff">public</font>
            <font color="#0000ff">static</font>
            <font color="#0000ff">bool</font> Update&lt;T&gt;(<font color="#0000ff">this</font><font color="#2b91af">Table</font>&lt;T&gt;
table, T instance) <font color="#0000ff">where</font> T: <font color="#0000ff">class<br /></font>{<br />
   <font color="#0000ff">try<br />
   </font>{<br />
      <font color="#008000">// do stuff here with parameters...<br />
      </font><font color="#0000ff">return</font> table.Foo()
&gt; 0;<br />
   }<br />
   <font color="#0000ff">catch</font> (<font color="#2b91af">Exception</font>)<br />
   {<br />
      <font color="#0000ff">return</font><font color="#0000ff">false</font>;<br />
   }<br />
}
</p>
          <p>
            <font color="#0000ff">public</font>
            <font color="#0000ff">static</font>
            <font color="#0000ff">int</font> Foo&lt;T&gt;(<font color="#0000ff">this</font><font color="#2b91af">Table</font>&lt;T&gt;
table) <font color="#0000ff">where</font> T: <font color="#0000ff">class<br /></font>{<br />
   <font color="#0000ff">return</font> table.GetEnumerator().Bar();<br />
}
</p>
          <p>
            <font color="#0000ff">public</font>
            <font color="#0000ff">static</font>
            <font color="#0000ff">int</font> Bar&lt;T&gt;(<font color="#0000ff">this</font><font color="#2b91af">IEnumerator</font>&lt;T&gt;
e) <font color="#0000ff">where</font> T : <font color="#0000ff">class<br /></font>{<br />
   <font color="#0000ff">return</font> 1;<br />
} 
</p>
        </code>
        <p>
Horrible example yes and for that I apologize.  Hopefully you see where I am
going with this and that if you are given a similar codebase it can be quite confusing. 
When I first heard of extension methods I though they were for simple utility tasks
such as outputting a decimal value as a dollar amount (again, doesn't <i>REALLY</i> warrant
an extension method but...):
</p>
        <code>
          <p>
            <font color="#0000ff">public</font>
            <font color="#0000ff">static</font>
            <font color="#0000ff">string</font> PrintWithDollarSign(<font color="#0000ff">this</font><font color="#0000ff">decimal</font> input)<br />
{<br />
   <font color="#0000ff">return</font> input.ToString(<font color="#a31515">"c"</font>);<br />
}
</p>
        </code>
        <p>
Simple. Effective. Here's how you would use:
</p>
        <code>
          <font color="#2b91af">
            <p>
Console
</p>
          </font>.WriteLine(instance.Price.PrintWithDollarSign());
</code>
        <p>
Cheap. No frills.  I <em>could </em>have just bypassed this extension method
altogether but it provides a very "Hello World"'y introduction to extension methods
for those of you not hip to them.  In my previous example if you had an object
with a <code>decimal</code> property and the value was 5.00 the output would be $5.00.
Easy.
</p>
        <p>
Anyone care to chime in on extension methods relying on other extension methods? I'd
love to get some feedback.
</p>
        <img width="0" height="0" src="http://www.31a2ba2a-b718-11dc-8314-0800200c9a66.com/aggbug.ashx?id=fde4b553-b25e-42aa-b519-b03819de3c6b" />
      </div>
    </content>
  </entry>
  <entry>
    <title>Adding unique indexes to SQL Tables</title>
    <link rel="alternate" type="text/html" href="http://www.31a2ba2a-b718-11dc-8314-0800200c9a66.com/2008/06/05/AddingUniqueIndexesToSQLTables.aspx" />
    <id>http://www.31a2ba2a-b718-11dc-8314-0800200c9a66.com/PermaLink,guid,7e8f9d2f-09bb-40c2-ba80-ac42f0d6f9cc.aspx</id>
    <published>2008-06-04T21:35:07-07:00</published>
    <updated>2008-06-04T21:41:23.6964894-07:00</updated>
    <category term="Dina" label="Dina" scheme="http://www.31a2ba2a-b718-11dc-8314-0800200c9a66.com/CategoryView,category,Dina.aspx" />
    <category term="NetTiers" label="NetTiers" scheme="http://www.31a2ba2a-b718-11dc-8314-0800200c9a66.com/CategoryView,category,NetTiers.aspx" />
    <content type="xhtml">
      <div xmlns="http://www.w3.org/1999/xhtml">
        <p>
Now that I'm diggging a little deeper into my pet project web site, I'm learning how
I really use the data. The Get() methods provided by .netTiers are great but I thought
I would have more. I started looking at my database starting with the aspnet_Membership
tables. I would expect unique indexes on something as obvious as the email column
but it is not there. Same goes for other obvious columns in these microsoft-provided
tables. So I add unique indexes to the membership tables. Of course, I do the same
for my own custom tables and find that some of the text or varchar(max) have to be
changed. No biggie but another step I have to take. 
</p>
        <p>
Now that the database is set, I need to regen the .netTiers templates, rerun the GrantUser
stored proc, build the .netTiers stuff and copy it into the /bin of my project. Not
hard work but just tedious to get each step completed and move on to the next one.
All this so my .Get methods are consistent with my usage of the library. 
</p>
        <p>
All this so I can get my validators working - I really hate validators. 
</p>
        <img width="0" height="0" src="http://dina.berryintl.com/Blog/cptrk.ashx?id=803b7e95-7370-46f0-a3dd-78e85b75b590" />
        <img width="0" height="0" src="http://www.31a2ba2a-b718-11dc-8314-0800200c9a66.com/aggbug.ashx?id=7e8f9d2f-09bb-40c2-ba80-ac42f0d6f9cc" />
      </div>
    </content>
  </entry>
  <entry>
    <title>New SQL security finds web.config hole</title>
    <link rel="alternate" type="text/html" href="http://www.31a2ba2a-b718-11dc-8314-0800200c9a66.com/2008/06/04/NewSQLSecurityFindsWebconfigHole.aspx" />
    <id>http://www.31a2ba2a-b718-11dc-8314-0800200c9a66.com/PermaLink,guid,09db9bad-a19a-41f0-add9-93efdd68577c.aspx</id>
    <published>2008-06-03T20:00:10-07:00</published>
    <updated>2008-06-03T20:07:51.8080122-07:00</updated>
    <category term="Dina" label="Dina" scheme="http://www.31a2ba2a-b718-11dc-8314-0800200c9a66.com/CategoryView,category,Dina.aspx" />
    <category term="Dina's Pet Project" label="Dina's Pet Project" scheme="http://www.31a2ba2a-b718-11dc-8314-0800200c9a66.com/CategoryView,category,Dina's%2BPet%2BProject.aspx" />
    <category term="NetTiers" label="NetTiers" scheme="http://www.31a2ba2a-b718-11dc-8314-0800200c9a66.com/CategoryView,category,NetTiers.aspx" />
    <content type="xhtml">
      <div xmlns="http://www.w3.org/1999/xhtml">
        <p>
Yesterday, I was reading the MSDN FLASH email newsletter and saw a listing for another <a href="http://blogs.msdn.com/sdl/archive/2008/05/15/giving-sql-injection-the-respect-it-deserves.aspx">SQL
injection</a> article. Since one of Wayne's sites was recently hacked, I thought I
would read it. The article is clear and gives explicit steps to take. Since I had
only done one of the three things (SQL stored procs), I thought I would mess with
the last one: execute permissions only. 
</p>
        <p>
Wayne pointed me to a <a href="http://www.mssqltips.com/tip.asp?tip=1203">stored
proc</a> to grant permissions to a user. Since users and roles are one of those
areas that after you have them set up correctly, you don't mess with them, I stumbled
my way through creating a user. I ran the stored proc (which will have to be run after
every .netTiers generation), modified my sql connection in web.config and tried
my pet project site. I get an error about SELECT statements and permissions.
.netTiers was supposed to be configured in web.config to use stored procs but apparently
not. So I change the file, build, and still get the error. Someone, somewhere is caching
something. Close everything done. Reopen. Change web.config and checkin with comment.
Test again and it works. 
</p>
        <p>
This is a really bad way to find a problem. It's getting to the point that I need
someone to check my security changes so this type of thing isn't missed. 
</p>
        <img width="0" height="0" src="http://dina.berryintl.com/Blog/cptrk.ashx?id=902fe6b5-446c-4463-a17f-1212a16ade54" />
        <img width="0" height="0" src="http://www.31a2ba2a-b718-11dc-8314-0800200c9a66.com/aggbug.ashx?id=09db9bad-a19a-41f0-add9-93efdd68577c" />
      </div>
    </content>
  </entry>
  <entry>
    <title>Free Personal Websites</title>
    <link rel="alternate" type="text/html" href="http://www.31a2ba2a-b718-11dc-8314-0800200c9a66.com/2008/06/02/FreePersonalWebsites.aspx" />
    <id>http://www.31a2ba2a-b718-11dc-8314-0800200c9a66.com/PermaLink,guid,0a730fc1-6692-4a20-9f22-7855a6c73270.aspx</id>
    <published>2008-06-01T19:52:45-07:00</published>
    <updated>2008-06-01T19:53:38.8965402-07:00</updated>
    <category term="Dina" label="Dina" scheme="http://www.31a2ba2a-b718-11dc-8314-0800200c9a66.com/CategoryView,category,Dina.aspx" />
    <content type="xhtml">
      <div xmlns="http://www.w3.org/1999/xhtml">
        <p>
Volume 14 of <a href="http://makezine.com/magazine/">Make Magazine</a> has an
interesting article on free web sites - web site builders that also host the end resulting
web site. 
</p>
        <img width="0" height="0" src="http://dina.berryintl.com/Blog/cptrk.ashx?id=3721f9ff-15c7-4504-a656-2fc6995df194" />
        <img width="0" height="0" src="http://www.31a2ba2a-b718-11dc-8314-0800200c9a66.com/aggbug.ashx?id=0a730fc1-6692-4a20-9f22-7855a6c73270" />
      </div>
    </content>
  </entry>
  <entry>
    <title>15seconds.com article: netTiers</title>
    <link rel="alternate" type="text/html" href="http://www.31a2ba2a-b718-11dc-8314-0800200c9a66.com/2008/05/30/15secondscomArticleNetTiers.aspx" />
    <id>http://www.31a2ba2a-b718-11dc-8314-0800200c9a66.com/PermaLink,guid,790fb36d-f7a4-489d-8393-e705c157496f.aspx</id>
    <published>2008-05-29T19:22:45-07:00</published>
    <updated>2008-05-29T19:30:57.2663618-07:00</updated>
    <category term="Dina" label="Dina" scheme="http://www.31a2ba2a-b718-11dc-8314-0800200c9a66.com/CategoryView,category,Dina.aspx" />
    <category term="NetTiers" label="NetTiers" scheme="http://www.31a2ba2a-b718-11dc-8314-0800200c9a66.com/CategoryView,category,NetTiers.aspx" />
    <content type="xhtml">
      <div xmlns="http://www.w3.org/1999/xhtml">
        <p>
Here is my latest article on 15seconds.com: <a href="http://www.15seconds.com/issue/080529.htm">http://www.15seconds.com/issue/080529.htm</a> titled
"Implementing the .netTiers Template Library as a .NET Website's Data Layer - Part
I"<br />
 
</p>
        <img height="0" src="http://dina.berryintl.com/Blog/cptrk.ashx?id=f9ad87eb-7db8-4266-bea5-5776bc3e4554" width="0" />
        <img width="0" height="0" src="http://www.31a2ba2a-b718-11dc-8314-0800200c9a66.com/aggbug.ashx?id=790fb36d-f7a4-489d-8393-e705c157496f" />
      </div>
    </content>
  </entry>
  <entry>
    <title>Crosspost from DasBlog to DasBlog</title>
    <link rel="alternate" type="text/html" href="http://www.31a2ba2a-b718-11dc-8314-0800200c9a66.com/2008/05/29/CrosspostFromDasBlogToDasBlog.aspx" />
    <id>http://www.31a2ba2a-b718-11dc-8314-0800200c9a66.com/PermaLink,guid,c03a1415-b1a6-4313-855b-5335daa4b5ea.aspx</id>
    <published>2008-05-28T21:46:55-07:00</published>
    <updated>2008-05-28T21:49:47.8148896-07:00</updated>
    <category term="Dina" label="Dina" scheme="http://www.31a2ba2a-b718-11dc-8314-0800200c9a66.com/CategoryView,category,Dina.aspx" />
    <content type="xhtml">
      <div xmlns="http://www.w3.org/1999/xhtml">
        <p>
Now I'm trying to get all my blogs tied together. Most are DasBlog so no big deal <strong>only
what is the endpoint? </strong>The documentation lists blogger.aspx off the root but
the file isn't there. Apparently from the forums I'm not the only one with the issue.
However, I thought I bet it is there virtual. So I enter that in the address bar and
I get a response of web service methods available. Nice - why doesn't the documentation
say the page isn't there but the dll will respond.
</p>
        <img width="0" height="0" src="http://dina.berryintl.com/Blog/cptrk.ashx?id=78ed3c66-b66b-4607-9235-fc4afc4aa798" />
        <img width="0" height="0" src="http://www.31a2ba2a-b718-11dc-8314-0800200c9a66.com/aggbug.ashx?id=c03a1415-b1a6-4313-855b-5335daa4b5ea" />
      </div>
    </content>
  </entry>
  <entry>
    <title>Cool clock on neighborhood-kids.com</title>
    <link rel="alternate" type="text/html" href="http://www.31a2ba2a-b718-11dc-8314-0800200c9a66.com/2008/05/09/CoolClockOnNeighborhoodkidscom.aspx" />
    <id>http://www.31a2ba2a-b718-11dc-8314-0800200c9a66.com/PermaLink,guid,83ed6bb9-6eeb-4a86-bf90-b265609bdab6.aspx</id>
    <published>2008-05-08T21:14:25.9494514-07:00</published>
    <updated>2008-05-08T21:14:25.9494514-07:00</updated>
    <category term="Dina" label="Dina" scheme="http://www.31a2ba2a-b718-11dc-8314-0800200c9a66.com/CategoryView,category,Dina.aspx" />
    <content type="xhtml">
      <div xmlns="http://www.w3.org/1999/xhtml">
        <p>
I get an email every friday about the new events for families on the weekend on <a href="http://www.neighborhood-kids.com">www.neighborhood-kids.com</a>.
The design is great. I love it, but my eyes and mind do skip over things in the page
just assuming they are pretty but useless. Then I noticed the clock at the top of
the page was right about the time. Wow, that is cool. I'm going to have to pay closer
attention to what is technically happening on web sites. 
</p>
        <img width="0" height="0" src="http://www.31a2ba2a-b718-11dc-8314-0800200c9a66.com/aggbug.ashx?id=83ed6bb9-6eeb-4a86-bf90-b265609bdab6" />
      </div>
    </content>
  </entry>
  <entry>
    <title>The sun is out</title>
    <link rel="alternate" type="text/html" href="http://www.31a2ba2a-b718-11dc-8314-0800200c9a66.com/2008/05/03/TheSunIsOut.aspx" />
    <id>http://www.31a2ba2a-b718-11dc-8314-0800200c9a66.com/PermaLink,guid,fe1fd904-66c5-4351-8ac8-982cbf6c3605.aspx</id>
    <published>2008-05-02T21:08:07.146-07:00</published>
    <updated>2008-05-01T21:08:07.1460114-07:00</updated>
    <category term="Dina" label="Dina" scheme="http://www.31a2ba2a-b718-11dc-8314-0800200c9a66.com/CategoryView,category,Dina.aspx" />
    <content type="xhtml">
      <div xmlns="http://www.w3.org/1999/xhtml">
        <p>
Living in the northwest is wonderful but when spring and summer start to show up (meaning
the sun makes a regular appearance), I totally loose all motivation. My brother from
England worked a summer for Boeing in Seattle a few years ago. He was shocked that
people didn't do any work in the summer. I was always luck at Microsoft to not have
a summer ship date. That would have totally sucked. 
</p>
        <p>
How can I think about writing code and the project when the sun is out just laughing
at me, taunting me to come out. 
</p>
        <img width="0" height="0" src="http://www.31a2ba2a-b718-11dc-8314-0800200c9a66.com/aggbug.ashx?id=fe1fd904-66c5-4351-8ac8-982cbf6c3605" />
      </div>
    </content>
  </entry>
</feed>