New article on the Blue River by Pat Dorsey

Pat Dorsey has a new article in the Feb 2006 issue of Fly Fisherman Magazine. It is a great article with incredible detail. Its a keeper.

Simple regex to strip HTML tags

It may not be perfect but it works for me:

string stripped = Regex.Replace(textBox1.Text,@"<(.\n)*?>",string.Empty);

Here is the original article from Roy Osherove' blog


Heading to the beach

We are heading to the beach for our summer vacation. No computers, no code, no bugs. Sun, beach, lobster, relaxation, a little fly fishing for stripers, and maybe a little bit of surfing (if the waves cooperate). I am really excited to get out of town and "press the reset button". See ya in 2 weeks.


Utility for running stored procs via the command prompt

I found a cool utility for running stored procs via the command prompt:


There is often the need to quickly run a stored-procedure from the
command-line because you don’t have access to Enterprise Manager or Query
Analyzer (especially when working with MSDE). Sure, you could use osql.exe to
run the stored-procedure, but what if you can’t quite remember what parameters
the stored-procedure takes or can’t quite remember the name? Well this is the
hole that nsqlsp was designed to fill. It comes in particularly handy for
calling system stored procedures (such as sp_addlogin).

Thanks to William Bartholomew


Article on Cheesman Canyon by Pat Dorsey

I just read a fantastic article in my September 2005 issue of FlyFisherman Magazine

Guide and fly tier Pat Dorsey shares his time-tested secrets for fishing to
the toughest trout in Colorado. This story includes a season-by-season
description of Cheesman Canyon, including hatch information, fly pattern
suggestions, and fishing strategies. Map, fly shops, and guide contact
information is also included.

It is an exerpt taken from his book which I am anxious to read:

A Fly Fisher's Guide to the South Platte River: A Comprehensive Guide to Fly-Fishing the South Platte Watershed

and it is available at the Blue Quill Angler in Evergreen, CO


Parent-Child combo boxes in C#.NET Windows Forms

I was fighting with a pretty simple scenario in a C#.NET Windows Forms project today. I was having trouble getting data binding to behave the way I wanted it to. I'm sure that other people have the same requirements in some of their apps: parent and child combo boxes.

  1. Bind controls on a form to a dataset called dsAddresses in this example. The parent and child SelectedValue are bound to CountryRegionID and StateProvinceID from this dsAddresses dataset.
  2. Populate the parent and child combo box items with data from country/region and states/provinces datasources (DataTables in this example) respectively
  3. When the parent combo box's selected value changes, have the items in the child combo box filtered automatically
This sounds pretty simple and like something that many of us would need to accomplish on a regular basis in both Windows Forms and ASP.NET Web Forms.
Well...I had a solution that was acceptable for the most part, but there was an few issue with the way that I implemented the solution.

Main issue: If you brought up the form and selected an address, the values in the parent and child combo boxes were bound to the correct values, but if you didn't select a country/region (which causes the SelectionChangeCommitted event to fire and this is where I called a method to filter the state/provinces manually in my previous solution) in the parent combo, the states/provinces combo would not be filtered and all states/provinces would show up.

I tried a number of workarounds and was about to scrap the entire original design of the form and start from scratch.

Brad Raulston gave me a hand and we tried a few things and then he researched it and found a blog posting by Andre King:

Parent-Child combo boxes in C#.NET Windows Forms

It detailed a scenario almost exactly like the one outlined above. I can't seem to get to the link at the moment but I was able to get the cached Google version.

Brad graciously helped me with the solution below:

Created a dataset called dsCountryState.
Merged 2 DataTables into it (because I already had them, but will refactor
to fill the dataset with both tables in one shot for efficiency later): one for
the parent Country/Region data and one for the State/Province data.

// Created a DataRelation for the parent and child DataTables like this:
DataRelation rel = new DataRelation("CountryStateRelation", dsCountryState.Tables["CountryRegion"].Columns["CountryRegionID"],

// Accept Changes on the dsCountryState DataSet.

// parent combo bound to the
"parent_datatable.parent_column"cboCountryRegion.DataSource =

cboCountryRegion.DisplayMember = "CountryRegion.CountryRegionName";

cboCountryRegion.ValueMember = "CountryRegion.CountryRegionID";

// child combo bound to the "parent_datatable.parent_child_relation.child_column" cboStateProvince.DataSource = dsCountryState;

cboStateProvince.DisplayMember = "CountryRegion.CountryStateRelationship.StateProvinceName";

cboStateProvince.ValueMember = "CountryRegion.CountryStateRelationship.StateProvinceID";

What this accomplishes among other things is the combo boxes share
the same BindingManager which enables the required behavior. States/Provinces
are filtered automatically.

Thanks to Brad Raulston and Andre King for
the help and information. Hope this saves you some time and frustration.


History of Fly Fishing

Interested in the history of Fly Fishing? I came across a great site dedicated to the history of Fly Fishing. It was put together by Andrew N. Herd. The site is available at http://www.flyfishinghistory.com/.

Here is an excerpt on the origins of fly fishing:

The first reference to fly fishing is in Ælian’s Natural History, probably
written about 200 A.D. Ælian was born in about A.D. 170 at Praeneste, where he
later held a religious post, dying in about A.D. 230. At some point he became a
pupil of Pausanias of Caesarea, who taught him rhetoric, and as a good student
Ælian also learnt excellent Attic Greek. He later studied history under the
patronage of the empress Julia Domna, and moving within her circle would have
allowed him to meet not only Galen, but Oppian.

Here is a history of hooks:

The hook had its origins in the gorge, a device used by many primitive cultures,
which is frequently found in prehistoric sites. Gorges were made from slivers of
bone, flint or turtle-shell which were attached to a line which was knotted
through a hole in the centre of the gorge. The fish swallowed the gorge end
first in a bait, and the pull of the line levered the gorge across the fish’s
throat, trapping it in place...

There is a lot more interesting information available at the site. Check it out!


GMAIL Invites

Don't have a GMAIL account?

I've got 50 GMAIL invitations if anyone is interested. Just leave me a comment with your email address and I'll send you one.


The RegexLibrary Builder for .NET

I just found this article on The Code Project. One
of the coolest things is that you can add, remove, and modify regexes
from a compiled assembly, so you fix or replace regexes without having
to recompile the entire project. It makes use of the CompileToAssembly
method in the System.Text.RegularExpressions namespace.

Here is a link to the article by Brian Delahunty:

The RegexLibrary builder allows you to:

Create CLS compliant Regular Expression Libraries - .NET assemblies
that contain only regular expressions
Add multiple regular expressions to a single assembly
Define individual names, namespaces, regex modifiers, and accessibility
levels on a per regex basis
Reload existing Regular Expression Libraries and add, remove, or modify
regular expressions contained within
Manually set the version number of the assembly to help ensure
compatibility with existing versions
Much, much, more... ;-)

Here is a link to the author's (Brian Delahunty) blog posting on the
tool: http://briandela.com/blog/archive/2005/06/03/284.aspx


Missed the Caddis

Dave and I got a pretty early start today. We stopped to get Dick's advice again and this time it didn't quit work in our favor. It wasn't anyone's fault, but more,weather screwed us. We gambled and decided to fish Brown's Canyon. It was partly cloudy and cool, then the wind whipped up, then the sun would show for a while, then cold again... Dave picked a few up on Puteraugh's foam bodied caddis, and I picked up a nice brown on a beadhead caddis pupa, but the caddis hatch really wasn't happening in Brown's Canyon.

We ended up catching more on baetis thanks caddis. Once again the Barr's Emerger was the ticket. And the funny thing was that we couldn't buy a fish on our favorite foam-winged flashback RSII today.

It got really slow in the late afternoon and we both considered, even if it wasn't verbal, that we were beating a dead horse. But the persistence payed off. We stayed later then any other fishermen and it made a decent day GREAT. Dave was the man of the hour.

Dave tied on a hi-vis parachute BWO with a Barr's Emerger trailer. We saw some regular risers in the slick water just in front of the car park (which is ridiculous because we walked miles up the canyon in our pursuit and caught the best fish right in front of the car). Anyway, Dave was max'ing out his 3 weight with long casts, putting in a small mend when necessary, and he managed to land four great fish. All but on took his Barr's Emerger. It was a hell of a site to see. He really worked it and that worked for him.

We were hungry as bear and decided to try to hit the Mr. K's or the Dinky Diner on the way home. We struck out, both were closed. We proceeded through heavy snow to Kenosha Pass where it cleared up. We stopped at one of John Woz' old hang-outs: Cactus Jacks. We scarfed some awesome burgers and headed home.

Great day, but not the Caddis Hatch we were expecting.


Headed to the Ark

DiamonD and I are headed to fish the Arkansas River tomorrow. The weather looks a bit iffy but we should have a nice time anyway. The Caddis are coming off according to the reports and the Baetis should still be getting some action from those browns. I'll post a followup to this to report on our success (or failure ;-)

xp_pcre - Regular Expressions in T-SQL

I just came across an article on CodeProject: xp_pcre - Regular Expressions in T-SQL By Dan Farino. It provides 6 different extended stored procedures to provide a range of regex functionality.

It uses the "Perl Compatible Regular Expressions" library which is available at http://www.pcre.org/

I haven't tried it but it really looks like a useful thing. I'll report on it soon.


Too Sexy For My Waders

I created a new blog: Too Sexy For My Waders. It is going to be a team blog for my fishing buddies: John Woz and DiamondD, and myself. We are going to catalog our annual fly fishing trips and all the wacky adventures along the way. Should be a crack.

Tying for the Ark

Dave an I had a tying session tonight for the Arkansas River. We tied up some foam-winged caddis, peacock caddis, and some mercury bead flashback pheasant tails. It was a good night of tying and Emma baked some Salmon. It was tasty.

Mercury Flashback Pheasant Tail Nymph
Pat Dorsey designed this variation of the already highly effective and popular pheasant tail. With its glass beadhead, it gives fish a slightly different look they go crazy for. Works great on hard-fished waters where trout have seen it all.

Puterbaugh's Black Foam Caddis
The pattern is available here

Peacock Caddis
The pattern is available here


Simple Perl and C# Regex Comparison

I have been working through Regular Expressions from Friedl. I have been testing the regexes in PowerGrep, EditPad Pro, Perl, and C# in .NET. Here is a very simply comparison:

Here is the Perl script borrowed from Friedl:

print "Enter a temperature (e.g., 32F or 100C):\n";
$input = ;

if ($input =~ m/^([-+]?[0-9]+(\.[0-9]*)?)([cC][fF])$/)
$InputNum = $1;
$type = $3;

if($type eq "C")
$celsius = $InputNum;
$fahrenheit = ($celsius * 9 / 5) + 32;
$fahrenheit = $InputNum;
$celsius = ($fahrenheit - 32) * 5 / 9;

printf "%.2f C is %.2f F\n", $celsius, $fahrenheit;

print "Expecting a number , then a \"C\" or a \"F\", so don't understand \"$input\".\n";

Here is a similar program written in C#:

using System;
using System.Text.RegularExpressions;
namespace Temperature1

/// Summary description for Class1.

class Class1
/// The main entry point for the application.

static void Main(string[] args)
Console.WriteLine("Enter a temperature to convert. (Examples: 0C or 32F)");
string input = Console.ReadLine(); // read input from user
string pattern = @"^([-+]?[0-9]+(?:\.[0-9]*)?)([CF])$"; // build regex pattern
Regex r = new Regex(pattern, RegexOptions.IgnoreCase); // Compile the regular expression.
Match m = r.Match(input); // Match the regular expression pattern against a text string.
string type = m.Groups[2].ToString();
double celsius = 0.0D;
double fahrenheit = 0.0D;

if(type.ToUpper()=="C") // convert from celsius to fahrenheit
celsius = double.Parse(m.Groups[1].ToString());
fahrenheit = (celsius * 9 / 5) + 32;
else // convert from fahrenheit to celsius
fahrenheit = double.Parse(m.Groups[1].ToString());
celsius = (fahrenheit - 32) * 5 / 9;

// at this point we have both temperatures, so display the results
Console.WriteLine("Result: {0,2:n} C is {1,2:n} F", celsius, fahrenheit);
// the initial regex did not match, so issue a warning
Console.WriteLine("Expecting a number followed by 'C' or 'F' so I don't understand {0}.", input);
catch(Exception e)

Regex in Perl definitely seems more natural and "built in".

Here is a link to Regex documantation on MSDN: .NET Framework Regular Expressions

More to come...


Working with Perl

I just installed ActivePerl from ActiveState. The installation was painless and so far it has worked perfectly. It's not that I really wanted to learn Perl, it is just that many of the examples in "Regular Expressions, Powerful Techniques for Perl and Other Tools" by Jeffrey E. F. Friedl, from O'Reilly are demonstrated in Perl. It seems like a really concise and powerful language.

Here is my progress...not much I know. Guess this is equivalent to "Hello World" for demonstrating regular expressions in Perl.

print "Enter a temperature in Celsius:\n";
$celsius = ;

if ($celsius =~ m/^([-+]?[0-9]+)([CF])$/) {
$fahrenheit = ($celsius * 9 / 5) + 32;
printf "%.2f C is %.2f F\n", $celsius, $fahrenheit;
print "Expecting a number, so don't understand \"$celsius\".\n";


Check out SpamGourmet

Eugeny Sattler informed me of a great Spam protection service. It is called www.spamgourmet.com. He did russian translation for the site www.spamgourmet.com It is a great site for spam protection, and he recommends it to everybody.

How spamgourmet works

If you give your email address to everyone, you are bound to receive spam emails, and you won't know where they came from. Wouldn't it be convenient to give a different email address to every business or web site, while getting all your email as before? Wouldn't it be easiest to assume the address will be given to spammers, and have it work as a spam blocker by shutting off automatically unless you decide otherwise?

That's exactly what spamgourmet offers!...


Arkansas River Beatis Hatch

Dave and I fished the Arkansas River upriver from Buena Vista, CO. Dick from ArkAnglers sent us there. It was a gorgeous spot and a beautiful day. There was too much sun (I know, what a terrible problem to have ;-) for much surface action early in the day. The clouds moved in and I'm sure the baetis hatch started right after we had to leave, but that is how it goes.

We were catching mostly browns and a few rainbows. Early in the day we were producing on green copper johns, Barr's emergers and olive foamwinged flashback RSII's. It got pretty warm and I had a slow spell for a good hour or two. Dave kept nailing them in the last whole with a barr's emerger. He was "working it". Slow, short, steady drift with lots of success. It was really cool to watch.

Here is a current fishing report from Arkanglers


Regular Expressions

I was just tasked with an interesting programming challenge this week. I used Regular expressions to solve it. I'm a total novice at using regular expressions, but I do see the value in using them for certain tasks. Wow, what a powerful technology!

I posted a question on a Google Group: Regex. I very generous and helpful developer by the name of Eugeny Sattler assisted me in solving this problem and helped me to gain a better understanding of Regular Expressions in the process.

I am evaluating a tools that take advantage of Regular Expressions. One being EditPad Pro. This is an excellent tool and I'm seriously considering purchasing this tool. I have been using EditPad Lite for a while now and really like some of it's features. The Pro version is just that much more powerful. Another tool that might be worth purchasing is RegexBuddy.

I am reading "Regular Expressions, Powerful Techniques for Perl and Other Tools" by Jeffrey E. F. Friedl, from O'Reilly. This is an excellent book. It is written in a way that really aids in the understanding of an otherwise complicated topic. I have only gotten through the first chapter so far, but I am already getting some of the basics down.

Another tool you might consider adding to your aresenal is a pre-compiled, windows-native version of GNU egrep can be found in the bundle at: http://unxutils.sourceforge.net/. Lots of goodies in there.


Great Birthday!

Had a great birthday. Dave picked me up at ~5:30 AM, we drove to the Colorado near Parshall, CO, we fished for a few hours and headed back early that afternoon. Dave is a hell of a guy to get up that early. He wasn't even grumpy.

The water was up from last week and a bit off-color. I was thinking that we weren't going to do very well but Dave picked up a few early on. We seined the river and found what looked like large dark sow bugs. I didn't know that there were sow bugs on the Colorado. Let me know if you know otherwise. We also found a ton of small baetis and other stuff. We put on a Ray Charles and an olive foam wing, flashback RSII and spanked them. Together Dave and I probably landed 40 fish. Great day on the water.

That evening, I went to the Galactic concert at the Fillmore Auditorium with Caroline, Kati, and my sister Nicole. Good show but I miss what Theryl added to Galactic. Maceo Parker was the opening band.

Gorgeous day on the Colorado

Diamond Dave working the seam

Gurkha Cigar

Dave with a nice brown

Releasing it for another day Posted by Hello


Willams Fork Confluence

Had a great fishing below the Williams Fork and Colorado Confluence. Got there at 7:15 AM and was the second guy in the lot. By the time I had my waders and vest on, there about 5 more cars all jockeying for position. I ended up with a good spot and caught a fair amount of fish on a glass bead, black D-rib midge. The fish started rising so moved the D-rib to the bottom and put an emerging Black Beauty on (Black Beauty with a z-lon emerging wing case). Both flies continued to catch fish.

I Met a nice guy Paul and learned a lot from him. I was fishing below another gentleman and he was doing really well. He had the best spot and got em on emergers and dries. I couldn't reach the risers and tried a few different dry\dropper combos with no luck.

I had to leave the fish at 11:00 to meet my wifey and kiddo at Mary Jane. We took turns hanging with Maddie and had great spring skiing. Sweet day all around!


Team Building in the woods

We spent a team building day in Fraser, CO. Nagesh, Sanjeez, Janel, Vera, Russ, Josh (me), Caroline, and Madeline had a nice time in the Experimental Forest.

Sanjeev, Nagesh, and Janel in the Experimental Forest near Fraser, CO.

More of the gang.

Madeline was a sport. She is always up for a free ride. Posted by Hello


Found a great article on mending by Philip Monahan while reading MidCurrent. Here is a link to the feed if you are interested.

Here is an excerpt...

"A good friend of mine, who has been a guide for many years, always draws a distinction between those clients who can cast and those who can actually fish . (He maintains that the former outnumber the latter by a wide margin.) Casting only helps you throw the line through the air. But the fish don't live in the air. They live in the water, and the water is usually moving."


Diamond Dave, Glenn, Eddy, Laney and I all hooked up in Alcova, Wyoming to fish the North Platte. Yolanda at Sloanes really set us up with a great room. It was a great trip even thought the fishing was a bit slow. The report from the Platte River Fly Shop was right on. It said "Fair - Possible to hook a few" and they weren't lying. The weather was great and the wind was pretty manageable all weekend. The flow was really low at 500 cfs and we had to row through a lot of water. Scuds and small baetis were the ticket. San Juan Worms and midges were also supposed to be good but no one but Dave caught anything on that that I remember. Great trip.

Here is a 23 inch Rainbow that I was lucky enough to hook on a slow Sunday afternoon. With lots of help and support from Eddy and Laney, we netted it, photogrpahed it and safely released it to fight again. Posted by Hello

Here is a shot taken by Eddy of both of us in his boat. Got to love a Nat Sherman once in a while. Posted by Hello

Here is a healther rainbow caught on Saturday. It took a size 14 orange scud. Laney netted it for me. Posted by Hello

Here is Glenn with a good sized Sucker fish. Posted by Hello

Look at the crazy Summit Guy. As my buddy Eddy says, this picture accurately captures the true essence of Summit Guy. Posted by Hello


Found a good SQL Programming resource. I found it on Aaron Weiker's blog

He's got good public forums


Found a great NASA resource where you can track satellites and space stations (if you are into that sort of thing ;-)) Posted by Hello

Found a new resource from Google. --> Google Maps


It seems to be very intuitive and works great considering it is a new beta. Check it out.


I just found the Alaska Fly Fishers (AFF) site and it has some good fly patterns and various other informamtion. Check it out.

Here are some of thier awesome pattern archives:

  1. H& L Variant
  2. Bead-head Soft-Hackle Pheasant Tail
  3. McFly Egg
  4. Glo-bug


We got some good snow this weekend and boy did we need it. These pictures were taken on Monday Jan. 31, 2005 (Althought the timestamps on the pics are off by 2 weeks...). Snow on the deck and in the valley. Posted by Hello

Snow on a tree in the front yard. Posted by Hello

Here is a shot of Maya. Posted by Hello

The dogs weren't much help this time. Posted by Hello

FlyFisherman.com has an article "Nymphing Without Indicators" by JIM MCLENNAN

Indicators may help new fly fishers catch fish but there are times when you don't want to use them....


Here is a collage from New Years Posted by Hello


Great day in Eleven Mile Canyon...
Dave and I had a good time fishing in Eleven Mile Canyon. It was a gorgeous day, a bit chilly in the AM, but it warmed up considerably It was pretty crowded too.

The fish were rising to midges and baetis, so we fished small dries with emerger droppers. We caught a lot of fish. Great time.

Griffith's gnat, size: 20-22
BWO sparkle dun, size: 22-24
Olive parachute, size: 22
Barr's emerger (flashback), size: 24
Young Special, tan, size: 24

The Pressure Myth
Does a changing barometer truly affect our fishing success? Let science answer that question.


Look at this. She is a happy girl! Posted by Hello

ASCII Chart and Other Resources