Drawing with HTML and Tables

Posted on 2007-06-24 at 15:53

Insane. Just insane. I want to see the final source code for this web page:

Make A Comment

The Word of God

Posted on 2007-02-20 at 21:05

Learn to love the xkcd.

Make A Comment

Klingon Rules Of Programming

Posted on 2006-06-09 at 21:23

A while back I posted the Ferengi Rules of Acquisition that have been so helpful to my thriving business, so it is only fitting that I also post the Klingon Rules of Programming as a follow up.

You have been warned.

Make A Comment

I am only 4 elements away from validation

Posted on 2006-05-23 at 08:08

When I first write the shell scripts that generate this site and all it's files, the ATOM feed format was still being designed. I used the v.3 spec. Now that it's released and the final version of the spec out there for use, I've been menaing to make the changes needed to have a valid ATOM feed. I made some headway this morning. I still need to address about 4 more issues, but that's a big improvement over yesterday's 20 or so issues.

If you have no idea what I'm talking about, don't worry, you too can learn about the ATOM feed!

Make A Comment

ASP.NET 2.0 thoughts

Posted on 2006-03-07 at 09:35

You can pick it up, clean it off, and shine it for the guests, but ASP is just a way to try to shove 15 pounds of dung in a 5 pound canvas sack.

ASP.NET 2.0 is far better than previous versions I've written for, but html just doesn't cut it as a medium for rich application development.

I understand the maintainence benefits are sustantial, but as a development platform, it blows.

Make A Comment

Web Development

Posted on 2006-02-21 at 13:10

My current assignment is a web development position (ASP.NET, specifically) and I'm once more reminded of what a dog Internet Explorer is. I got menus for the site implemented in pure css. It was elegant, simple, and did all that a menu needed to do. Then what happened? I tried it in Internet Explorer. Though it works beautifully in other browsers (becuase they implement actual standards!), IE was a no go. I had to hack it up and defecate on its beauty before it would work in IE. It works in all browsers now, though, and it's still almost entirely CSS.

Anyone that tells you they got a cross-browser compatible menu system implemented in "pure css" is a lying sack of dung. The best solution I could find was to implement the IE fixes in an htc file, which is really just a bunch of javascript code to do for IE what IE should have already done for itself. Still, at least the htc solution left my actual CSS code mostly unharmed. Anyone that wants the code is free to ask me for it. I used some stuff that was GPL'd and pulled in examples from all over the web to get it as I wanted it.

Make A Comment

Dear Diary

Posted on 2006-01-20 at 16:55

Today I brought 16 quad-processor servers to their knees. The client whose servers were made to weep openly are impressed with my ability to stop all database activity companywide by hitting F5 in SQL Server's Enterprise Manager. Apparently it's a bad thing when SQL Server reports the number of rows returned in scientific notation because it's otherwise too large to display.

I hope they still love me in the morning.

Make A Comment

Mono and Gnome APIs

Posted on 2006-01-13 at 14:45

I've said it before. I'll say it again. Linux will not ever become mainstream until it can make itself more approachable by the average corporate programmer.

I like Mono and what they have done for Gnome. But let's step back and look at the big picture. We need our own API, not a reworked version of one Microsoft has handed us. Take what's good about .NET and Java and come up with a new API that is specific to the Gnome platform. Moving away from a reliance on Sun or Microsoft's propriatary works, rightly or wrongly, will help to bring the community together. Additionally, making that new standard approachable in the way that Java and .NET are will help bring new developers to the Gnome platform.

Remember that Windows has users because it has applications. It has applications because it courts the average corporate programmer successfully. Gnome could learn a bit from that. It means slaughtering a few sacred cows of the Gnome world. An example? How about drag-n-drop form design? This is not an afterthought. If you want to be taken seriously by the corporate programmer community (the people you NEED to be taken seriously by!) then this is an absolute requirement of every IDE. Period. No debates. And I don't mean some sort of decoupled Glade interface that you can reference in your code, but an integrated drag-n-drop form designer where you can doubleclick a control and write the code associated with the default action of that control. I can design a gui in code just like you, but frankly I'm not gonna. Not when Visual Studio (hands down the best IDE on the planet right now...and I am an ardent Linux supporter) offers me so more simpler a way to do the same thing. Do you hear me Monodevelop? Do you hear me Eclipse? I'm talking to you!

Make A Comment

Crystal Reports Header Trick

Posted on 2006-01-13 at 12:11

Problem
I have a Crystal Report with a chart in the group header and the details for the chart in the details section. How do I get the headings for the details to repeat on every page? I can't put them in the Page Heading since they wouod then print above the chart on the first page and it would look odd.

Solution
Create a formula called "FakeGroupForHeader". In that formula, say "whilereadingrecords; 1". Next, insert a new group using that formula as the basis and tell it to repeat the group on each page. This will result in there being only one grouping with no unique data. Wrap the details section in the new faked group, then put the detail headings (that would normally go in the page header) in that group's headings. Voila. You know have headings that repeat every page, but only under the chart (which is in the group heading for the parent group). Problem solved.

Make A Comment

repetition is repetition is repetition is ...lame

Posted on 2005-12-14 at 08:07

Stare at SQL Code.
Hit F5.
Too many records returned. Change search criteria.
Hit F5.
Too many records returned. Change search criteria.
Hit F5.
Too many records returned. Change search criteria.
Hit F5.
Too many records returned. Change search criteria.
Hit F5.
Too many records returned. Vomit on self.
Welcome to my workday.

Make A Comment

All my latest scripty goodness

Posted on 2005-12-09 at 08:02

Some of you have asked which blog application I use. Well, I don't use one. I just write my blog in xml and then I render that xml in html for the benefit of my reading public. Recently, I made a bunch of changes (see previous entries) to the design and structure of the site. Teh design changes are obvious, since you can see them on your screen, but the structural changes are really far more interesting to me (and to you if you are a geek).

Whereas I used to let the client browser transform and render the xml (using xsl and css), I know pregenerate the rendered html. Also, I used to have a redirect page as my index.html, which redirected visitors to whichever was the most recent blog page. Now I keep the most recent blog page in sync with the index page. This is because google dislikes redirects and it hurts my Google PankRank score. Now I can have a stable front page (like I used to a while back) that can enjoy a decent PageRank. For the curious, the script follows:

echo "Moving to the correct directory"
cd /mnt/tomde/

echo "Generating html from xml"
for xmlFile in *.xml; do
    xmlto --skip-validation -x main.xsl html $xmlFile;
done

echo "Cleaning up the generated html"
for procFile in *.proc; do
    sed 's/<br><\/br>/<br\/>/g' <$procFile >$procFile.1
    sed 's/ xmlns:atom="http:\/\/purl.org\/atom\/ns#" xmlns:dc="http:\/\/purl.org\/dc\/elements\/1.1\/"//g' <$procFile.1 >$procFile.2;
done

echo "Renaming the .proc files to .html files"
for htmlFile in *.proc.2; do
    newName=`echo $htmlFile | sed "s/.proc.2/.html/"`
    mv $htmlFile $newName;
done

echo "Removing the old .proc files"
rm *.proc*

echo "Getting current month and year"
currentDate=`date`
currentYear=`date +%y`
currentMonth=`echo $currentDate |awk '{print $2}'`
currentFile1="
case "$currentMonth" in
    "Dec")
        currentMonthNum="12";;
    "Nov")
        currentMonthNum="11";;
    "Oct")
        currentMonthNum="10";;
    "Sep")
        currentMonthNum="09";;
    "Aug")
        currentMonthNum="08";;
    "Jul")
        currentMonthNum="07";;
    "Jun")
        currentMonthNum="06";;
    "May")
        currentMonthNum="05";;
    "Apr")
        currentMonthNum="04";;
    "Mar")
        currentMonthNum="03";;
    "Feb")
        currentMonthNum="02";;
    "Jan")
        currentMonthNum="01";;
esac
currentFile2="_$currentMonthNum\\.html"
currentFile=$currentFile1$currentFile2

echo "Getting the previous month and year"
previousDate=`date --date="$(date +%Y-%m-15) -1 month"`
previousYear=`date +%y --date="$(date +%Y-%m-15) -1 month"`
previousMonth=`echo $previousDate |awk '{print $2}'`
previousFile1="
case "$previousMonth" in
    "Dec")
        previousMonthNum="12";;
    "Nov")
        previousMonthNum="11";;
    "Oct")
        previousMonthNum="10";;
    "Sep")
        previousMonthNum="09";;
    "Aug")
        previousMonthNum="08";;
    "Jul")
        previousMonthNum="07";;
    "Jun")
        previousMonthNum="06";;
    "May")
        previousMonthNum="05";;
    "Apr")
        previousMonthNum="04";;
    "Mar")
        previousMonthNum="03";;
    "Feb")
        previousMonthNum="02";;
    "Jan")
        previousMonthNum="01";;
esac
previousFile2="_$previousMonthNum\\.html"
previousFile=$previousFile1$previousFile2

echo "Updating the site feed"
currentFeed2="_$currentMonthNum.xml"
currentFeed=$currentFile1$currentFeed2
rm feed.html
rm feed.xml
cp $currentFeed feed.xml

echo "Updating the site's main page"
newIndex1="
newIndex2="_$currentMonthNum.html"
newIndex=$newIndex1$newIndex2
rm index.html
mv $newIndex index.html

echo "Cleaning up old edit remnants"
rm

echo "Current Blog Month: $currentFile"
echo "Done"

echo "Closing..."
sleep 1
echo "10"
sleep 1
echo "9"
sleep 1
echo "8"
sleep 1
echo "7"
sleep 1
echo "6"
sleep 1
echo "5"
sleep 1
echo "4"
sleep 1
echo "3"
sleep 1
echo "2"
sleep 1
echo "1"

Because I run this from a button on my gnome panel, I added the sleep commands to the end so that I could review the feedback for issues before the command window closes. I figured 10 seconds was enough, but I liked seeing the time count down.

If anyone has a question about the abve script, feel free to ask. Click on the "comment about this entry" link above to do so. I gotta run to pick up Cadence from the sitter's. I'm running late...waaaay late. I'm a bad dad. :(

Make A Comment

Full Remote Collaboration on Programming Projects

Posted on 2005-10-12 at 08:01

This Gobby thing is pretty neat! It allows multiple people in disparate locations to edit the same source code text file at the same time, and chat while doing it. Very cool. Not sure that I'd ever need it, but if I did at least I know it's there. I dig it.

Make A Comment

Laszlo and the WeatherBlox example app

Posted on 2004-10-07 at 08:01

[WeatherBlox applicaiton removed from the blog because it stopped working right]
Laszlo is an Open Source XML-based alternative to Macromedia's Flex technology. It's a server-side XML markup language for creating dynamic javascript apps. Like Flex, it dynamically produces Flash files. Very cool stuff.

Make A Comment

And speaking of .NET development in Linux

Posted on 2004-08-13 at 08:02

I've drooled and waited, and yet still after all this time still no Fedora install packages for MonoDevelop. Who do I gotta smack to get this done?!?

Make A Comment

My First Linux App

Posted on 2004-08-13 at 08:01

Having now written an app for Linux, I am left wondering what I should use my newfound great powers for. Forthwith, I present to the world, the "Click the Damn Button!" application written in C#, using GTK#, and compiled to run in mono on Linux:

using System;
using Gtk;

public class ButtonClicker
{
    public static void Main()
    {
        Application.Init();

        Window window = new Window("Click The Damn Button!");

        Label label = new Label("Name");
        Entry entry = new Entry();
        Button button = new Button("Click Me!");

        window.DeleteEvent +=
            new DeleteEventHandler(window_DeleteEvent);
        button.Clicked += new EventHandler(button_Clicked);

        VBox vbox = new VBox();

        HBox hbox = new HBox();
        hbox.PackStart(label, false, false, 12);
        hbox.PackStart(entry, false, false, 12);
        vbox.PackStart(hbox);
        vbox.PackStart(button, false, false, 12);

        window.Add(vbox);
        window.SetDefaultSize(200, 100);
        window.ShowAll();

        Application.Run();
    }

    static void window_DeleteEvent(object o,
                DeleteEventArgs args)
    {
        Application.Quit();
        args.RetVal = true;
    }

    static void button_Clicked(object sender, EventArgs e)
    {
        Console.WriteLine("You clicked the button!");
    }
}

Where is the proof that it works, you ask? Well, suck on this screenshot, bizzotch:

Make A Comment

Monodevelop

Posted on 2004-03-04 at 08:04

Monodevelop gets its own web site. Additionally, it has put out its first release!

Make A Comment

Monodevelop

Posted on 2004-02-23 at 08:01

I'm really starting to drool over the upcoming release of monodevelop. Much goodness will be had.

Make A Comment