Tuesday, January 31, 2012

This one is a public service announcement. A little light on the entertainment value. Sorry.
So here's the deal: sometimes you're writing a document that has specific word count requirements for various sections. I run into this all the time writing manuscripts. Various journals will have word limits for different sections: an abstract of no more than 250 words, an introduction of no more than 1500 words, and so on. As you type, Microsoft Word gives you the total word count for your document, so you only have an idea about whether the first section of your document fits within the allotted word count. The kludgy workaround is to copy and paste each section into a new document, which will give you the total word count for that section. Annoying. Even more annoying if you were over-budget, and have to make repeated edits and checks until you come in under the limit. Wouldn't it be great if you could get a section-by-section word count breakdown? You can. I wrote a macro to do just this. To begin, you have to make use of section breaks, which are nothing more than a means to group different sections of text together. You can insert them between any chunks of text you would like, according to your needs. Once you've done this, you can get the word count for each section with this macro:

Sub SectionWordCount()

    Dim NumSec As Integer
    Dim S As Integer
    Dim Summary As String

    NumSec = ActiveDocument.Sections.Count
    Summary = "Word Count" & vbCrLf


    For S = 1 To NumSec
        Summary = Summary & "Section " & S & ": " _
          & ActiveDocument.Sections(S).Range.ComputeStatistics(wdStatisticWords) _
          & vbCrLf
    Next

    Summary = Summary & "Document: " & _
      ActiveDocument.Range.ComputeStatistics(wdStatisticWords)
    MsgBox Summary
End Sub

Create a new macro in MS Word, copy and paste this code into the VB Editor and you're good to go.

I don't think this one will be nearly as popular as my Catan series.

Saturday, January 28, 2012

When I eat out (anywhere), I'm just as interested in reverse engineering my meal as I am in enjoying it. Moreso, perhaps. Far from having the stereotypical bachelor's* limited repertoire of meals I can cook, I've mastered a number of classics in my adult life. Lately, my best meals have been those involving a cheese sauce: macaroni and cheese, cheese and potato or broccoli soup being my go-to favourites.

The reason for this proclivity is not so I can have culinary arts as a fall-back career, but the more practical concern of being able to make something edible out of my refrigerator contents given my grocery shopping habits: First, I hate grocery shopping so in the days leading up to my grocery excursion, the foods I work seldom present an obvious menu. Second, when I do buy groceries, I go completely nuts in the produce department. On one hand, that's how the finger-waggers would say you should shop. On the other hand, it means thins in my shopping cart start expiring at random intervals over the next week or two in a manner not dissimilar to the spontaneous ejection of subatomic particles from a decaying radioactive isotope. Monitoring these decaying food items often results in questions like, "hmm, these green onions and these pears are going to have to go in the bin after tomorrow. What can I make with green onions and pears?" Hence the need to build a library of reverse-engineered food items in my head, for my required food pairings may necessitate unconventional substitutions.

One saving grace, however, has been my box-fan blow-hard 3000 (dehydrator) made to Alton Brown's specifications. After attempting to turn some overripe plum tomatoes into their sun-dried variant, I inadvertently discovered that completely dehydrated vegetables can be run through a spice mill and turned into a vegetable powder. In the case of powdered tomato, it makes pasta sauce extra tangy and thick.


 *These are the sorts of projects one can only do when living alone, and that is the sense in which I am a bachelor. I remain married to my wonderful wife.

Tuesday, January 10, 2012

Road Rage

The holidays have ended for most by now. Mine were sort of extended when my family came back with me for the new year. I returned just this afternoon from driving them back home and received a final gift of the season: a brush with road rage. I was coming off the I-55 junction, where it meets up with Lake Shore Drive, right at Chicago's Field Stadium. I try to maintain a constant distance between myself and the car in front of me, which I believe to be prudent, as the abrupt reduction of this distance to zero is a leading cause of accidents. The car in front of me braked. I braked in response. I assume the car behind me braked, but the driver was not very pleased with this chain of events, as, in addition to braking, she honked her horn at me. A moment later, she passed me on the left. Now, cars were braking because traffic along this stretch is controlled by several stop lights, many of which are wont to turn red. Thus, no sooner than she passed me than all lanes came to a stop. The light was red. And so it was that I came to a stop along side this woman's car as she presumably captured a look of bewilderment on my face to see her awkwardly pointing her DLSR camera over the rear passenger window at me. And when I was right alongside her, she continued to snap photos of me. I rolled down my window to explain to her that one cannot go faster than the car in front, but she would hear none of it (for her window remained rolled up). Thus, I didn't even get the satisfaction of explaining myself, not that not plowing into the car in front of me should demand an explanation.

At first I was quite bothered by this. To some degree, I still am, though the edge was dulled somewhat when I was mulling over the title of this blog entry. My first thought was to entitle it Cr*** Bit**, but it was then it occurred to me that the woman might actually have a DSM-qualified problem. I mean, she had a camera at the ready within seconds of passing me. Is this habitual? Whether it is, or she found it while fumbling through her camera bag while driving on a freeway, neither possibility seems the mark of someone particularly rational, nor particularly good at driving. Maybe she was irritated with me because she nearly plowed into my back end while taking a photograph of the previous driver who irked her.

So now that I have written about it, I am mostly over the ordeal. I wholeheartedly encourage you to google "a**hole Canadian driver" or something like that. Who knows? Maybe this woman intends to shame me by posting my perplexed picture on the internet or something. If you do come across my picture, do let me know so I can use it as my facebook profile picture. My only regret is having neither the resources nor the quick wit to have hastily scrawled "Will you marry me?" on a whiteboard. It would give me some satisfaction to think I might cause her to stroke out when she reviewed the photos on her flash card, thereby getting one crazy driver off the road.

Monday, January 9, 2012

I subscribe to both Netflix services: streaming video (which has replaced cable) and the 1 DVD service, which is more than enough to accommodate the very slow trickle of new releases I find worth watching. I often resort to adding old favourites to fill in the long gaps in between worthwhile new releases -- for example, Unbreakable, which even ranks among my wife's favourites.

The disk arrived in the mail last week and, well...



I am leaving the comments section open to accommodate the flame war that may now proceed as to whether this qualifies as irony.

Wednesday, January 4, 2012

Freenuptials

I just read to my delight that the honourable Peter Mackay, Canadian Defense Minister, wed former Miss Canada World Nazanin Afshin-Jam. Though I'm quite happy for the couple, I couldn't help but wonder whether he went with the traditional wedding limo, or planned to call the reception dinner a military exercise so the blissful couple could be whisked away to the carribean on a CF-18. Passenger jets are for suckers.

Key Change

A little less than three weeks ago, I packed up for my holidays, tucking my office keys into a pouch in my extremely pockety Prism U backpack. I had forgotten about them until this morning, as I was leaving for work. I found them before leaving the house. I did not have them when I got to my office door. Thinking this was yet another case of absent-minded organization, I figured I had left them on a counter at home. When I got home, I found this not to be the case. I retraced my path to the shuttle bus stop and found my carabiner key chain on the ground in the middle of the parking lot.

So, I admit this perhaps isn't the most amazing story ever, but it seemed really triumphant at the time, because I was in a really, really sour mood until I found my keys.

Still feel this entry a little lacking? Okay, let me sweeten the pot a little by sharing a billion dollar idea I had last night. I know many people are not very keen on genetically modified organisms, but I think those people will change their tune when they consider how awesome it would be if some entrepreneurial spirit released a swarm of bees altered to inject you with Botox. Crow's feet got you down? Throw a few rocks at the hive up in the tree and wait for the magic to happen! You're welcome!

Monday, January 2, 2012

Cuneiform

Little known fact: Before Moses brought down the ten commandments from Mount Sinai, his first challenge was to select an appropriate tablet. The usual depiction of Moses bearing two tablets illustrates that he was ultimately unable to decide between iOS and Android.


I received an Android tablet this Christmas. It wasn't anything especially fancy, which is fine, because I hadn't yet researched the hell out of it, and indeed wasn't even sure I wanted a tablet computer. I kind of did. But I kind of also want a jet pack and mutant healing factor, so ...

Though it's a little underpowered for some of the fancier business that the kids are doing these days (I was unable to play a Netflix stream on it, for example), it does play video off the external MicroSD card just fine. And after installing the Aldiko eBook reader app, the device now essentially functions as a Kindle with movies and Angry Birds. I now also have an opinion on the Android Market (versus Apple's App Store), which I found somewhat difficult to navigate -- partly because of the peculiarities of my device, but also because it contains many, many apps written for Asian markets, with no means of filtering them. I have, however, found Amazon apps to be a fine venue for filling up the storage on my device.