Cool .NET Tips and Tricks #17
By Dr. Dexter Dotnetsky
There is no "Printer - Friendly Version"
Dr. Dotnetsky

Howdy, Dr. Dotnetsky here again! Hey, why did the multithreaded chicken cross the road? TheOtherSide.toGetTo(). (Don't worry if you didn't "get" it - the punchline will be different every time).

Rants about stuff I don't like Dept.

Dr. Dotnetsky doesn't like a lot of things, but then, that's just the nature of the cranky, irreverent personality he's developed over the years. (After all, Dr. Dotnetsky's first computer was a Commodore 64, and most of the people reading this today aren't old enough to even remember when the first IBM "PC" came out.) By the way, for those who are afficionados of history:

The First real "PC":

On August 12, 1981, IBM released their new computer, re-named the IBM PC. The first IBM PC ran on a 4.77 MHz Intel 8088 microprocessor. The PC came equipped with 16 kilobytes of memory, expandable to 256k. The PC came with one or two 160k floppies and an optional "color" (like, 3, man) monitor. The price tag started at $1,565. (Shortly after, as Dr. Dotnetsky recalls, the stock market went into a nasty dive.)

Now one thing Dr. Dotnetsky really doesn't like is developer - oriented web sites that don't work. An example of this is GotDotnet.com This site, at over three years old, is by Internet standards, well into the "alta cacca" (that's Yiddish slang for "old fart") phase and the developers who put it together simply haven't kept up with the traffic. It is a good site, it has a huge number of user samples, the vast majority of which conform to the unwritten credo of "sharing the source code to your creation". There are, of course, some "commercial demos" and similarly disguised "samples" up there which the staff claims they can't stop for legal reasons (Jeesh! What a buncha BS!), but on the whole, it's been a very useful site.



The problem is this site shouldn't be allowed to have an Internet Driver's License anymore. Where it really falls off (big time) is in the usability / scalability domain. Remember, this is a site put together by Microsoft people for Microsoft developers and the whole idea of it, therefore, is to show off how great the .NET Platform is. So you go to join a Workspace and you install the UserControl for source control, and you get this:

Other typical behavior includes verrrrrrry long waits for page loads and similar annoyances. Once, when Dr. Dotnetsky was younger and working on Mt. Tamalpias in Mill Valley with a buddy, doing some ranch - type work for a family friend, an old gardener - type guy named "Bob" used to come up and he always said "First Impression's the last one, ya know!" So, How 'Bout It, guys! Dr. Dotnetsky was gonna make a contribution to the new Plumbwork Orange WSE infrastructure project -- but he never can seem to get in to download the damn source code! And the HTML - only interface sucks BIG TIME. Most of the serious people have already moved their stuff to SourceForge.net (hint, hint!) .Hey, Dewds -- why put all this glorious crap together for people if you can't ever seem make it work? There's NO EXCUSE for this kind of unprofessionalism! There - vented my spleen and I actually feel better already.

NOTE: In all fairness, I will say that one educated reader pointed out they do have the "standalone" .NET Framework version of the control in a WinForms Wrapper at http://workspaces.gotdotnet.com/wksalone. It's sloooow, but it does work.

New Tips and Tricks

Here are a few of the latest new (and perhaps not so new, but valuable nonetheless) tricks that Dr. Dotnetsky has run across since last rant:

Application - Level Caching:

Keith Warren blogs about a nasty bug involved in caching objects in Application_Start and using a CacheItemRemoved Callback to reload the cache:

http://weblogs.asp.net/kwarren/archive/2004/05/20/136129.aspx

(in ASP.NET 2.0 we have a much more robust set of Cache options including the new SqlDependencyCache and custom cache dependency items)

As a side note, Dr. Dotnetsky is quick to praise GOOD work too, and I will say with no hesitation that Scott Watermasysk has done a top-notch job with weblogs.asp.net. The quality of the posters and their content is to be much admired (and that's from a dude that still thinks Blogs Suck!).

Intellisense Schema Generator:

BlueVision Software has a free product that can generate the Intellisense schema for your custom ASP.NET Server control. Very Nice! (and did I mention "free", as in Stoli Martinis?) Find it here: For those who don't know what this is, in HTML view, when you start to type something, a list of choices comes up. This list is created by an XSD Schema file referenced in the <BODY> tag of the document by its urn. These schemas also control the behavior of the object in the Design View editor, such as look and feel, whether they permit absolute positioning and so on. Very useful stuff!

MSDN Community Blogs Search Aggregator

"Blogs, schmogs!", Dr. Dotnetsky would typically say. However, I keep an open mind and here is something very interesting that the MS people have put into place: http://www.microsoft.com/communities/blogs/PortalHome.mspx. In a nutshell, this is a search facility over all the Microsoft personnel blogs (the ones hosted on the communities site, and it looks like even some that are hosted elsewhere) that allows you to search by Blogs or individual posts, then by Category (similar to the 20 - odd categories on MSDN search) and then by optional keyword(s). The result can be requested as a custom RSS feed! Very nice, instead of getting bombarded by blogs about whose cat died or whether they liked the latest version of Starbucks Asynchronous Callback Mocha Delight, you can get a custom RSS feed that you can consume any way you like, with stuff only pertaining to what you want! Now that's progress!

Dr. Dotnetsky would really like to see a "Master Blogregator" site that functions like the "Google of Blogs" to do this for ALL blogs everywhere. Then I'd be real interested. In the meantime, in the name of improving the signal to noise ratio, this idea is a nice step in the right direction! Hell, I'd even pay $2 a month to subscribe (or be willing to look at their ads, as long as they didn't invade my damn INBOX!)

WTF is Happening to America Dept.

Here's a snippet that says it all, from a right wing web site devoted to Michael Moore's rampant egomania and narcissistic personality disorder (right wing?-- you can't be anything but to the right of this joker, since his big mouth and fat ass don't permit room for anything to the left of him!):

"All of this [news of how well Farenheit 911 was doing in theaters] had to be the absolute worst news for the White House to wake up to on Monday morning. I guess they were in such a stupor, they "gave" Iraq back to, um, Iraq two days early! "

That's correct, this egotistical boor Moore actually believed that the Coalition turned Iraq back over to the Iraqis two days early -- to try and deflect attention away from his movie! Sick puppy, man! Moore's moral universe is essentially an illusion. The basis of his public persona is the carefully crafted image that he is a knockabout, blue-collar guy from a blue-collar family who grew up in a quintessentially blue-collar town, Flint, Michigan, an industrial city that's since been screwed by the giant corporations he despises.

Problem is, Michael Moore is from Davison, a very WHITE COLLAR neighborhood, and everything else Michael Moore stands for is a lie, including his numerous statements abroad about what terribly stupid people we Americans all are. One day soon, something will happen and Moore will fade into the sunset of the persona-non-grata, to be replaced by another, similar idiot with a different name.

 

Summer Coolers Department:

What rant would be complete without the famous . . .

Dr. Dotnetsky's Cajun Martini recipe

Pour a fifth of vodka into a large jug. (Yay!)

Add 2 or 3 fresh jalapeno peppers (sliced, seeded,etc. ), and a single red chili pepper.

Let sit in the refrigerator for 2 days.
Shake with ice and vermouth in a 5 to 1 ratio, garnish it with a pepper.

Comments:
Now this really will get you hopping! The only problem Dr. Dotnetsky has had with this one is the part about letting it sit in the fridge for 2 days....

What kind to use? Here are the latest rankings from VodkaPhile. I'd hasten to add that most of these are NOT made from potatoes, even though vodka was invented in Poland, not Russia, and made almost exclusively from potatoes. Note that most typical "yuppie brands" are not on the top of this list, the real connossieur's list:

RANK 2001

RANK 2000

RANK 1999

RANK 1998

BRAND COUNTRY

1

15

3

2

Grey Goose

France

2

2

2

--

Cristall

Russia

3

--

--

--

Krolewska

Poland

4

--

--

--

Youri Dolgoruki

Russia

5

13

1

6

Finlandia

Finland

6

--

--

--

Jewel of Russia

Russia

7

--

--

--

Vincent

Holland

8

6

10

5

Rain

US

9

11

5

1

Ketel One

Holland

10

1

--

--

3 Olives

England

11

--

--

--

Russian Standard

Russia

12

5

--

--

Vox

Holland

13

3

4

8

Stolichnaya

Russia

14

--

--

--

Vermont Spirits White

US

15

4

8

3

Absolut

Sweden

A politically correct note: For those who have problems with France and Russia, you can drop down to a respectable number three from Poland (they invented the stuff anyway, remember?) who is a staunch US ally with real troops in Iraq, with the Krolewska brand, made by the same people who produce Luksosowa, which is, indeed -- made from potatoes.

Well, I hope that all gives you "drink for thought!" I'll put more on this one in a bit, but I gotta write some code! Giddyap, Chicken!

Cheers,

-- Dexter

Dr. Dexter Dotnetsky is the alter-ego of the Eggheadcafe.com forums, where he often pitches in to help answer particularly difficult questions and make snide comments. Dr. Dotnetsky holds no certifications, and does not have a resume. Always the consummate gentleman, Dr. Dotnetsky can be reached at youbetcha@mindless.com.  Dr. Dotnetsky's motto: "If we were all meant to get along, there would be no people who wait for all the groceries to be rung up before starting to look for their damn checkbook."