Scott Hanselman

Looking for Senior Software Developer at Corillian

May 17, '06 Comments [19] Posted in ASP.NET | XML | HttpHandler | HttpModule | Tools
Sponsored By

We are looking to add a Senior Software Developer to our Consumer Banking team here at Corillian.  Are you "just the right person"?  If you are, then you fit the following description:

You know web development inside and out and can explain the HTTP protocol and HTML to your mother.

You have deep expertise with development using Microsoft ASP.NET.  You know the page event model, the control event model and the difference between a HTTPModule and a HTTPHandler and when each makes sense.

You understand how DOM and SAX parsers function, how XML schema works and how it is fundamentally different than database schema.

You know that TDD really means "write the test first"
 
You know how to read code, not just write code.

You are prepared to do what it takes to deliver value to the customer.

You work with others in an environment that encourages new ideas and improvement.

You have experience using a source control tool other than VSS.

You are willing to live in Portland, OR.  (To be a part of our team, you have to be here.  No telecommuting.)

About Scott

Scott Hanselman is a former professor, former Chief Architect in finance, now speaker, consultant, father, diabetic, and Microsoft employee. He is a failed stand-up comic, a cornrower, and a book author.

facebook twitter subscribe
About   Newsletter
Sponsored By
Hosting By
Dedicated Windows Server Hosting by SherWeb

Psychic Weight- Life is Pending

May 17, '06 Comments [5] Posted in Musings
Sponsored By

HanselglutWow, this post really nailed it. Sometimes I read a post and wish I'd written it and this is one of them.

Here's a choice bit:

With the amount of crap being vomited up by his Ethernet connection -- all day, every day -- it's tough to walk away from the spigot for fear that he'll return to waist-deep water. Ethan reads his mail in real-time to avoid being greeted by a hundred-message pile-up when he gets back from lunch. Bringing the computer with you is the only way to keep up. [greg @ an entirely other day]

Here's my pending life:

  • Voice-mail messages at work: 2
  • Voice-mail messages at home: 9
  • Voice-mail messages on my cell: 3
  • SMS messages on my cell: 5
  • Hours of television on the DVR: 17
  • E-mail messages at home: 525
  • E-mail messages at work: 67 (I was at 0 last week...)
  • Items in my feed reader: 4929
  • Books on my nightstand: 23
  • Active Projects at Work: 6
  • Active Projects at Home: 9
  • Homes Pending Sale: 1

Go read the post, then, if you feel like it, change your life. I think it's time for a large garbage sack and a little Ctrl-A, Del action...

Now, to be clear Getting Things Done works, but one of the risks of gaining the ability to filter lots of information is the psychic weight of all the worlds information. Folks start a new personal system of organization into order to handle some amount, x, of life that is coming at them. When that number x becomes x^2 the need to filter and when singing the refrain Do It, Defer It, Delegate It, Drop It, the Drop It part becomes especially important. 

Don't lose track of what's important. As much as it may pain me, I think I'll have to miss this week's Grey's Anatomy and probably not read the pending feed items this week.

About Scott

Scott Hanselman is a former professor, former Chief Architect in finance, now speaker, consultant, father, diabetic, and Microsoft employee. He is a failed stand-up comic, a cornrower, and a book author.

facebook twitter subscribe
About   Newsletter
Sponsored By
Hosting By
Dedicated Windows Server Hosting by SherWeb

Upgrading to a Canon Pixma MP500 Multifunction Inkjet Priner

May 16, '06 Comments [5] Posted in Reviews
Sponsored By

We awoke today to find that our trusty Canon S300 Printer had died. It was a great crappy little $50 printer that we had just used up. Noisy, but with great output, cheap ink and fantastic photos if you use good paper.

I shopped around BestBuy today and finally decided on the Canon Pixma MP500. It's got everything we wanted and way more.

  • Duplex Printing - Total bonus and a great feature.
  • Color Copier - Big on the WAF, this lets my wife Mo easily make copies without using the PC.
  • Scanner - Very simple TWAIN drivers let me dump my old and flakey Canoscan N650U.
  • Two paper trays - Feels like the office. I can put photo paper in one and regular in the others
  • Borderless 4x6 or 5x7 Photo Printing - Amazing quality from my Casio 7.2M Camera.
  • 2.5" Color LCD - Didn't think I'd like this, but it's actually pretty useful and shows details about how much ink is left.
  • PDFs - You can scan directly to PDF, which'll be useful for documents. It is literally one-button as it auto-names files and puts them in My Documents. I actually prefer this kind of "Just Do It" UI. I my write an app to help though...
  • Quiet Mode - You can give it a time of day (I said from 9pm to 7am) to run extra quiet while printing. Slows down to make it happen.
  • Memory card slots - These actually mount as disk drivers, but unlike cheapo memory card adapters, the drives only exist while the memory card is in the slot. It's always lame to have empty drives E: through L: that I don't use, but take up space in My Computer. Seems like a small detail, but it's a good think.
  • IR Support - Print directly from Camera Cell phones
  • Digital Camera Support - Prints from USB Digital Cameras

Bad stuff:

  • I was totally unable to run the included CD-ROM's setup, as it crashed when I pressed install. However, I was able to download just the drivers and not the craplets and it worked fine.

In retrospect (a short 1 hour later) I probably should have purchased the Canon Pixma MP800 since it's only $25 more on Amazon, and has 512 nozzles instead of 320 on the MP500, but really, who can tell the difference? Not I. All in all, we're thrilled.

One other note, no matter what printer you end up getting, no printer is complete without a copy of FinePrint. You can advanced and editable print-preview for all applications and printer-independent sizing/tiling. If you want to print 4-to-a-page duplex, no problem.  If you print a web page and see that it's 2 pages, but the second page is half empty, just delete it, visually, before it gets to the printer. What a great way to save paper.

About Scott

Scott Hanselman is a former professor, former Chief Architect in finance, now speaker, consultant, father, diabetic, and Microsoft employee. He is a failed stand-up comic, a cornrower, and a book author.

facebook twitter subscribe
About   Newsletter
Sponsored By
Hosting By
Dedicated Windows Server Hosting by SherWeb

Making Junctions/ReparsePoints visible in PowerShell

May 12, '06 Comments [1] Posted in PowerShell | XML
Sponsored By

CmdjunctionI'm not sure if this the right way to do this, and I'm sure someone more clever will speak up but...I use a lot of junctions/reparsepoints in my development here, and I was used to seeing them called out when I typed "dir" from cmd.exe.

(Notice in the screenshot from cmd.exe that the "foo" directory is actually marked <junction>)

In PowerShell when you type Dir, you're getting an Array of System.IO.FileInfo/System.IO.DirectoryInfo objects that are displayed using some default formatting. That default Formatting is a combination of two things, a Type definition and a View definition.

First, there's no "Mode" property on a DirectoryInfo, so how is one being shown? In PowerShell you can "tack on" new properties with Script. This isn't derivation, as it's type extension. Adding to functionality, type-wide (within the context of PowerShell) for any .NET type. So, in C:\program files\Windows PowerShell\v1.0\ there's a file called types.ps1xml that has this little bit of info:

  <Type>
        <Name>System.IO.DirectoryInfo</Name>
        <Members>
            <ScriptProperty>
                <Name>Mode</Name>
                <GetScriptBlock>
                     here's where the magic happens...
                </GetScriptBlock>
            </ScriptProperty>
        </Members>
    </Type>

So, I created a personal My.Types.Ps1.xml file in my PSConfiguration folder that looked like this, where 1024 is the value of the [int]([System.IO.FileAttributes]::ReparsePoint) enum and "-band" is "bitwise and."

<Types>
   <Type>
        <Name>System.IO.DirectoryInfo</Name>
        <Members>
            <ScriptProperty>
                <Name>ExtMode</Name>
                <GetScriptBlock>
                    $catr = "";
                    if ( $this.Attributes -band 1024 ) { $catr += "j" } else { $catr += "-" };
                    if ( $this.Attributes -band 16 ) { $catr += "d" } else { $catr += "z" };
                    if ( $this.Attributes -band 32 ) { $catr += "a" } else { $catr += "-" } ;
                    if ( $this.Attributes -band 1 )  { $catr += "r" } else { $catr += "-" } ;
                    if ( $this.Attributes -band 2 )  { $catr += "h" } else { $catr += "-" } ;
                    if ( $this.Attributes -band 4 )  { $catr += "s" } else { $catr += "-" } ;
                    $catr
                </GetScriptBlock>
            </ScriptProperty>
        </Members>
    </Type>
    <Type>
        <Name>System.IO.FileInfo</Name>
        <Members>
            <ScriptProperty>
                <Name>ExtMode</Name>
                <GetScriptBlock>
                    # Added the extra "-" to make sure things line up when FileInfos and DirectoryInfos are listed together
                    $catr = "-"; 
                    if ( $this.Attributes -band 16 ) { $catr += "d" } else { $catr += "-" } ;
                    if ( $this.Attributes -band 32 ) { $catr += "a" } else { $catr += "-" } ;
                    if ( $this.Attributes -band 1 )  { $catr += "r" } else { $catr += "-" } ;
                    if ( $this.Attributes -band 2 )  { $catr += "h" } else { $catr += "-" } ;
                    if ( $this.Attributes -band 4 )  { $catr += "s" } else { $catr += "-" } ;
                    $catr
                </GetScriptBlock>
            </ScriptProperty>
          </Members>
     </Type>
</Types>

Then in my Microsoft.PowerShell_profile.ps1 (the file that gets executed every time I start a PowerShell) I added:

$profileTypes = $profile | split-path | join-path -childPath "My.Types.ps1xml"
Update-TypeData $profileTypes

Now, I'm not sure how to get dir (alias get-childitem) to use MY ExtMode rather than its own, but I think I'd need to override the default View Definition. It's a little tricky with these scoped XML files, because I originally named my new property "Mode" and was chastised for my efforts:

Microsoft.PowerShell, C:\Documents and Settings\shanselm\My Documents\PSConfigu
ration\My.Types.ps1xml(39) : Error in type "System.IO.FileInfo": Member "Mode"
is already present.

So, I named it "ExtMode." We shall see if there's a better way, until then, this function worked.

function edir
{
 dir | select ExtMode, LastWriteTime, Length, Name
}

and got me this output. Notice the "j" now in the ExtMode column.

Psedir

If I can't override dir's default view, I probably could also have removed the alias for "dir" and replaced it with my own:

if (test-path alias:\dir) { remove-item -force alias:\dir }
set-alias dir edir

but edir is fine for me now.

About Scott

Scott Hanselman is a former professor, former Chief Architect in finance, now speaker, consultant, father, diabetic, and Microsoft employee. He is a failed stand-up comic, a cornrower, and a book author.

facebook twitter subscribe
About   Newsletter
Sponsored By
Hosting By
Dedicated Windows Server Hosting by SherWeb

Disclaimer: The opinions expressed herein are my own personal opinions and do not represent my employer's view in any way.