Outlook Signatures

Sometimes I don’t want a signature in Outlook. I’m tired of highlighting and erasing my corporate mandated signature with all the legal jargon on it on internal facing emails. Is there a quick way to do that?

I have three signatures in my Outlook; 1) External Signature, 2) Internal Signature and 3) Blank.

For the external signature, I put all the fancy logos, legal jargon and phone numbers and emails.

For my internal, it literally says, "Thanks, Curt, Phone#".

My last one is named Blank and has nothing in the signature body. The advantage to having that last one is that when I select it, Outlook is smart enough to remove the previous signature.

So, I can leave my external signature as the default and select the Blank signature to quickly kill the previous signature when I’m just replying to people or creating a really informal email. This saves a few seconds of selecting and deleting and keeps me from accidentally keeping the small font formatting in my email from the legal jargon at the bottom.

Let me know if this helps you out!

Quick Database Table Tests

Sometimes, I need to quickly test things out in SQL Server with a table. Today, I had a question about a BIT field. I was wondering what would happen if I put the value of 2 in it in an INSERT statement. Remember, BIT columns can stored only the value o (zero) or 1 (one).

I had a feeling that it would result in a 1 value in the database without throwing an error. But, to prove my point, I did this little test:

DECLARE @t AS TABLE (b bit)
INSERT @t (b) VALUES (0)
INSERT @t (b) VALUES (1)
INSERT @t (b) VALUES (2)
SELECT * FROM @t

I didn’t have to create a new table in the system to test it. Instead, I used a TABLE variable. Using a TABLE variable is very convenient. The table goes away as soon as the script is complete and I get my results fast. Here were the results in case you’re curious:

image

Yep. Inserting that 2 just resulting in another 1.

So, next time you have a question about a value in the database and want to see for yourself exactly what the database will do, play around with the TABLE variable. It’s really easy to do.

Flush Print in SQL Server Query Analyzer

How do I write a message to the Message tab in SQL Server 2005 query analyzer? PRINT statements are all queued up and don’t show up until the entire script is printed. Is there a FLUSH statement of some sort to output the print queue?

There isn’t a flush statement. However, there is an alternative to PRINTing your messages. You can raise an error that isn’t really an error (code of 0) and you’ll get the same effect–your message will be printed immediately.

Here’s the statement:

RAISERROR('Hello World', 0, 1) WITH NOWAIT

Pretty soon, you’ll be raising fake errors all over the place and getting the results you want. Sure, it’s a hack but it works great.

Let me know if it works for you!

Microsoft PowerToys for Windows XP

How do I open a command line window from where I’m browsing in Windows explorer?

There are still a lot of people out there that are running Windows XP. I’m one of them. Both at home and at work. I just started a new job and one of the things that I missed from my previous configurations is the "Open Command Window Here" feature.

It had been a while since I installed it and I used it so much I thought that it was a part of default XP install–but its not.

However, that you can download it from Microsoft’s web site. It is one of many, neat and free little utilities lumped together as PowerToys for Windows XP.

Check out and see if there is anything that you like.

Pachelbel’s Canon

In the summer of 1986, I graduated from high school.

I got a nice sum of money for graduation and was able to buy myself a 300 baud modem for my Tandy Color Computer II with Microsoft’s Disk Extended Color Basic 1.1.

This was the kind of modem where you had to dial the phone number with a phone, wait for the carrier tone, press a button on the modem and then hang up the phone real quick while the modems shook hands.

I remember that summer with fondness.

I would call BBSs (Bulletin Board Systems), all over the United States–mostly Atlanta though. Calling out-of-state from Barnwell, SC then was actually cheaper than in-state long distance. I have no idea what it is now since all of my long distance is free.

I eventually figured out how to get it for free then too from an LD carrier that I won’t name. There were codes you could dial before making the call that would make the call not show up on your bill. I have no idea whose bill it showed up on.

Before I learned how to phreak though, I racked up a huge phone bill that I paid for my Dad for several months. I was working at a Greek restaurant making pizza’s. It was hard work but the pizza was awesome.

That summer, I would wake up around 10:00 am, go to work for a while during lunch, come home, sleep some more and then go back to work around dinner time until around 11:00. Then, that’s when the fun began. I’d connect to BBSs,  check my mail, download new files and try to hack into systems.

I managed to hack into a few weather stations, a large grocery chain, and the serial network front end to a large, super computer company by making the device crash and then playing around in the debugger.

I was pretty active on CompuServe as well and racked up a hefty monthly bill there too. My CIS id was 75457,2535. You can still find files that people have pulled from CIS with my name and number in it. Here’s one from years later with some neat Delphi code that I wrote. I haven’t looked at that in years. I eventually became a SysOp on several CompuServe Time Warner forums and hung out in the Zenith forum’s chat rooms.

This was all way before the Internet and AOL. I learned a lot that summer.

I didn’t have a lot of money back in those days. So, my CoCo was my only machine. I had written a new RAM disk that I hand assembled into machine code and then wrote a program to write the binary file so that I could execute it. At the time, I didn’t have the money to buy the EDTASM cartridge for that. I didn’t know that what I had written was called a RAM disk. I just knew that I had figured out how to access and put to use the extra 32k of memory that was in my second bank of RAM that the OS didn’t know how to reach.

One night, I downloaded this really neat program called Canon. I didn’t really know what it was and the description said that it played some really nice classical music with faked multiple voices. The CoCo could only generate one tone at a time but if you oscillated the tone fast enough you could fake it well enough that your ear couldn’t really distinguish the fact that it was changing so quickly. The end result was really impressive.

That’s the first time that I ever heard Pachelbel’s Canon. I must have listened to that song 100 times that night just staring at the screen and day dreaming about what I was going to do with the rest of my life. All I knew is that I wanted to figure out how to create software like this.

Now, as I sit here working on this new interface to iiX that I’m documenting, I’m listening to the Shoutcast Internet radio station DroneZone. There’s an ambient/techno version of Canon playing.

I can’t help but marvel at how much things have changed in the last 22 years. It seems that my life has become a canon upon itself. This time around though, my daughter and son are near their graduation in a few years.

I wonder what they’ll be doing after they graduate from high school. I can’t help but to be reminded of E. B. White’s "Once More to the Lake" and the sudden chill of death.

Word 2007 Updates Entire Document On Its Own

Why is Word 2007 updating everything in my entire document to look like the small change I just made to one section or portion of my document?

I’ve been struggling with fixing all of the bizarre, out-of-the-b0x behavior that I got when I upgraded from Word 2003 to Word 2007. One of the things that has been driving me nuts all day is when I select a few lines of code, and make a change, such as adding bullet points, suddenly the entire document gets instantly modified in the same way. In this case, filled with bullet points! This is not what I was going for.

Figuring it had something to do with styles, I studied them for a while and noticed this interesting check box near the bottom of the Modify Style dialog box named "Automatically update" (shown below) .

image

Now . . . good luck finding anything about this in the snazzy new online help with no index. I tried searching for it by name and adding Modify Style to the search criteria but to no avail. And, no, clicking the question mark up there and hovering over the checkbox or clicking on it won’t pull up anything on that check box either. Neither will highlighting the field and pressing F1. I guess context sensitive help is too 90’s for Word now.

So, being the ol’skool hacker that I am, I just played around with it a little while and discovered that if you are working on a piece of text that has a style on it and the style has this checkbox checked, any changes you make to the text formatting-wise in the document will automatically update the style and subsequently change everything in the document tagged with that style! Wicked huh?

When I discovered this, I quickly looked at my Normal style and sure enough, the check box was checked. So, I unchecked it and the problem was solved.

Consequently, on the Normal style, after I unchecked the box, the entire check box disappeared from the Modify Style dialog box for that style altogether. Interesting eh?

I think this is telling and I’m willing to bet there is a bug in there somewhere when loading documents from previous versions of Word.

So, watch out for this. I have now taken the time to go back to all of my styles in the document and uncheck the checkbox above and life has been much better since.

I hope this helps you. Let me know if it does!

Snooping in .NET Libraries

How do I view the source code for some .NET libraries that I have but I don’t have the source code?

I’ve recently started a new job with a software development company that has a substantial amount of source code and a huge class library. I’m trying to get my arms around it and I’ve found that loading the hundreds of projects in Visual Studio can be very time consuming.

So, I downloaded Lutz Roeder’s .NET Reflector. It is a wonderful tool for the browsing into .NET libraries and you don’t need the source code to do it.

Here’s a screen shot:image

This program will let you click around in the disassembled code and on the various types. You can learn a class library quickly by exploring like this. You get a good peek "under the hood" so you can have a good feeling for how things are put together.

Keep in mind though that the disassembled code may have some name mangling. That’s OK. If you have the real source code, you can open the project and then take a look. I think using this tool is much quicker than using VisualStudio to find things sometimes.

There’s no substitute for knowing exactly what a class library does because you’ve seen the code first hand. Download this utility and give it a whirl.

Let me know what you think.

Free PDF Writer

Where can I get a free PDF writer for Windows?

Many, many years ago, I used to use Ghostscript. In order to create a .PDF file, you had to use an HP LaserJet printer driver and print to a PostScript file. Then, you would have to shell out to DOS and call the Ghostscript command line utility to convert the PostScript file to a PDF. Kind of a pain but it worked very nicely and it was free.

Now, it’s even much easier. Just download and install PrimoPDF and you’ll be cranking out PDF files in no time. I’ve been using this for a few years now with great success.