I had a need to import some CAD drawings into my Visio document. The CAD drawings were provided to me as PDF documents. Visio has no native way to insert a PDF into a drawing. SnagIt to the rescue. Besides being an excellent app for making screenshots, it installs itself as a printer. Well, all I did was print my PDF to the SnagIt printer, saved the image as a TIFF, and then inserted the TIFF into my Visio drawing.

The resolution was quite good and I achieved exactly what I wanted. Gotta love it when shits works out!

Enhanced by Zemanta

I’ve been toying around with SQL Server CE replication. For whatever reason, my code was failing with the following exception when I called Synchronize():

Failure to connect to sql server with provided connection information. sql server does not exist, access is denied because the iis user is not a valid user on the sql server, or the password is incorrect.

As it turns out, if you use the follow form of the SqlCeReplication ctor (as observed using Reflector):

public SqlCeReplication(string internetUrl, string internetLogin, string internetPassword, string publisher, string publisherDatabase, string publication, string subscriber, string subscriberConnectionString)

the PublisherSecurityMode is set to SecurityType.NTAuthentication. Otherwise, if you use the parameterless ctor, PublisherSecurityMode is left to its default, which is SecurityType.DBAuthentication. This assignment is NOT documented.

I am working on a SQL Server 2005 Reporting Services (SSRS) report that has differing row colors based on a value in each data row.  The color value is defined in the database.  When I initially created the report, each row had a variable background color but the foreground color was black.  The first time I ran the report, my dark blue background didn’t contrast well with my black foreground.  I quickly realized that I needed a way to vary the foreground color programmatically based on the background color.  After first discussing things over with Nate, here is the expression I came up with for the Color property of the table row:

((CInt(Fields!Status_Color.Value) And &HFF) * 299) +
((CInt(Fields!Status_Color.Value) >> 8 And &HFF) * 587) +
((CInt(Fields!Status_Color.Value) >> 16) * 114)
) / 1000) < 125,

Let me explain where this all comes from.  First off, the color that is stored in the database is used by a VB6 program.  VB6 stores colors as BGR and .NET stores colors as RGB (well, technically aRGB).  The first step is to break down the value from the database to its constituent parts (red, green, and blue) using bitshift operations I learned from Keith Peters and then apply the contrast formula I found from Colin Lieberman‘s website. I then determine that if the blackground is a dark color, then we use white and for a light background, black.  This appears to working like a charm.

Last night we purchase an Apple TV (as well as a Mac Mini, 20″ Cinema Display Monitor, wired keyboard, and wireless mouse). Today I had the unfortunate happenstance of making this little gem of a unit find, and talk to iTunes running on my Mac Pro. I’ll save you the gory details buy my switch is a Linksys SRW224G4P and in the end, I had to disable IGMP Snooping. Otherwise the multicast traffic wasn’t flowing around correctly. This fix came as “well, let’s just see if we turn the helper off”. Well sure as shit, it worked. Yippee for me!

I wanted to report that I succeeded in using iSCSI (on an Openfiler server) with Time Machine via a gigabit link with jumbo frames (MTU of 9000) enabled. The secret to my success? I used the iSCSI initiator from http://www.small-tree.com/. It appears as if the iSCSI initiator from globalSAN is just a plain broke down piece of shit. Well, you do get what you pay for. Hurray for me and my buddy Steve over at Small Tree!

I just came back from Dallas early this morning. I parked my car (for the last time) at Avistar (they are changing their name to FastTrack Airport Parking). Avistar operates 2 off-site airport parking facilities at Newark Liberty International Airport. Both lots are on US Route 1 & 9 with one location at Haynes Ave. and the other at McClellan St. Long story short, they racked up over 20 miles of joy-riding in my car while they had it. This was evidenced by a completely screwed up driver’s seat and extra miles on the odometer.

Since I picked up the car up at around 1:00 AM, I didn’t bother walking back into the office. There is no manager on duty (just a handful of minimum wagers) at night. After repeated calls today, I finally spoke with the manager, Steve Martin. Not that it’s all too surprising, he denied any wrongdoing. He claims the vehicle was dropped off with 1777 miles on it, when I took note of it being at 1748 when I dropped that car off. He dismissed the seat change as it sometimes happens, however I doubt it ever happens to this extreme.

I asked to view the surveillance video for the time I was in the lot. Of course he said no. I told him my next call was to the Newark Police Department, and he said go right ahead. A very helpful women at Newark PD said that this is a civil matter. The next step, if I so choose to pursue this, is to subpoena the footage. I’m not so sure this is worth it because by the time the subpoena is issued, I would expect the footage to be destroyed. I think airing this out online is sufficient recourse. Don’t you?

A simple word of advice, DO NOT USE AVISTAR / FastTrack Airport Parking.

Today my wife read to me an excerpt from a thread at one of her favorite discussion sites regarding the socioeconomic makeup of non-vaccinators and breastfeeders. A study concluded that people who either breastfeed, didn’t vaccinate or a combination of both had a tendency to be well educated, high income earners. These findings set off a flaming thread debating the well educated/high income earning findings.

One argument in particular is that high income earners do not come in contact with individuals that have had complications resulting from not vaccinating. Look, here’s my take on it. It all comes down to the fact that generally speaking, most people are stupid, ignorant, poorly educated, or just plain dumb. The correlation between high income earning and higher education is that smarter people make more money (for the most part, perhaps with the glaring exception of the Spears family). The only exception that I find to the more education/more income argument is that if the individual has decided to become a professor and therefore has taken a vow of poverty.

All you have to do is look around you to see examples of how stupid our society is. Most people are searching the web for pictures of Britney Spear’s pudenda (it’s Latin, look it up) rather than for information regarding the perils of vaccination. MySpace and Facebook are far more exciting for the average web user than La Leche League’s homepage. Who is the individual who rises above the din and reads sites that actually matter? The well educated (and subsequently higher earner) is the surfer that reads sites that matter, and furthermore it is the well educated surfer that understands what they are reading. The general populous wouldn’t understand the information even if you were able to get them to read the sites in the first place.

It all comes down to the truth; something that most people are entirely unwilling to mention in public. Most people are stupid, and it’s the well educated (read: smarter) minority that rise above the crap in the media, and search for answers on their own. Oh, and that’s another point. Finding these answers require some level of effort. A willingness to put in extra effort to accomplish something is often a prerequisite to being a high earner. Remember, psychology is the study of the obvious and sociology is the study of the painfully obvious. The answers are right in front of you if you are willing to look for them.

I had another idea. Top wage earners tend to afford themselves better health care. Better health care comes from better educated doctors. Low wage earners are often relegated to clinic level care, and at that level, they shoot everyone, and as fast possible because they have no way of knowing if the child will ever come back for the balance of their shots. Again, just the truth.