Thursday, October 19, 2006

I gave notice on Monday and October 27th will be my last day. Having spent almost two years working the same job, I felt more and more that it simply wasn't working for me and I didn't see my job or that feeling changing in the future. I wasn't improving my skill set and I had little opportunity to apply the ones that I had. I wasn't learning or growing in a field that demands both.

After all of the excitement of Aaron's arrival quieted down, I spent some time thinking about and looking at other options. I did a bit of interviewing. I turned down one offer, decided not to pursue another possible offer and didn't make the cut with a third company. None of the possibilities really excited me.

In the end, I have decided to take an entirely different direction: That of the contractor / consultant. I think that I am getting a good start by loosely partnering with Dewaard and Jones. I have known Bob for 3 years and have always enjoyed working with him. Bob wants to move into more of a sales, design and architecture role which has opened up a coding role for me. I think these two roles should complement eachother nicely. I will also be working with Rob Schripsema and Dick Dewaard.

In addition, I plan on putting time into a couple of web based business ideas of my own. Things that I have wanted to try for a while but I never was able to put the time into them. My new position should give me a little bit more scheduling flexibility and provide me an opportunity to balance these different priorities.

I know that there is more risk in this new venture but the near zero risk of my previous job was driving me crazy.

kick it on DotNetKicks.com   Thursday, October 19, 2006 3:06:23 PM (Pacific Standard Time, UTC-08:00)  #    Disclaimer  |  Comments [2]  | 

I just installed the RTM version of IE7 and still having an issue with OWA (Outlook Web Access) on Exchange 2003. I have tried two different servers from three different clients and IE generates an exception when I hit the send button after composing an email.

I found a few references to uninstalling the S/MIME control using the "Add/Remove Programs" Control Pannel but attempting that resulted in a rather comical error: "Another version of this prodcut is already installed... use Add/Remove Programs on the Control Panel."

The short term solution is to disable the S/MIME ActiveX control in IE7. Tools -> Internet Options -> Programs -> Select the "Managed add ons" button at the bottom. Then select the "Add-ons that have been used by Internet Explorer" from the drop down list. Select the "Mime Control Version Class" from the list and disable it under the settings.

Seems to solve the issue for me.

kick it on DotNetKicks.com   Thursday, October 19, 2006 9:43:16 AM (Pacific Standard Time, UTC-08:00)  #    Disclaimer  |  Comments [0]  | 
 Monday, October 09, 2006

I have beem following Spirit and Opportunity since their arrival more than 2.5 years ago. This is simply the coolest thing in a long time. Gotta renew my membership in the Planetary Society.

http://marsrovers.jpl.nasa.gov/gallery/press/opportunity/20061006a.html

kick it on DotNetKicks.com   Monday, October 09, 2006 7:05:20 PM (Pacific Standard Time, UTC-08:00)  #    Disclaimer  |  Comments [0]  | 
 Sunday, October 08, 2006

I just updated my blog to the new version of dasBlog and hope to blog on a more regular basis.

Life has been busy... Anouncing the arrival of Aaron Martin Robinson. Born August 6th. Aaron's arrival and my marriage to Jennifer are clearly the two biggest events in my life. Oh and how life has changed!

Lots of additional pictures over on my photo site including the birth action shots:

http://photos.binaryocean.com/?path=Aaron

kick it on DotNetKicks.com   Sunday, October 08, 2006 6:56:06 PM (Pacific Standard Time, UTC-08:00)  #    Disclaimer  |  Comments [0]  | 
 Wednesday, June 21, 2006

Had a customer ask for this functionality. Easily done. I can see using it in most of my GridView applications. You could modify this to recursively move throught e.Controls and find the first TextBox.

protected void GridViewMain_RowDataBound(object sender, GridViewRowEventArgs e) {

    if (e.Row.RowIndex == GridViewMain.EditIndex && e.Row.RowIndex != -1) {

        const string selectScript = "<script language='javascript'>document.getElementById('{0}').select();</script>";

 

        Control control = e.Row.FindControl("TextBoxQuantity");

        if (control != null) {

            Page.ClientScript.RegisterStartupScript(this.GetType(), "FocusEditTextBox", string.Format(selectScript, control.ClientID));

        }

    }

}

 

kick it on DotNetKicks.com   Wednesday, June 21, 2006 7:29:29 PM (Pacific Standard Time, UTC-08:00)  #    Disclaimer  |  Comments [0]  | 
 Friday, March 17, 2006

The compiler is typically pretty smart when it comes to string literals. Take a look at your code with Reflector and the debugger disassembler.

static void Main(string[] args)

{

    string a = "A" + "B" + "C" + "D" + "E" + "F" + "G";

    Console.WriteLine(a);

}

 

//reflector:

private static void Main(string[] args)

{

    string text1 = "ABCDEFG";

    Console.WriteLine(text1);

}

 

//but it not smarter than your application:

static void Main(string[] args)

{

    string a = "A";

    string b = "B";

    string c = "C";

    string d = a + b + c;

    Console.WriteLine(a);

}

 

//reflector:

private static void Main(string[] args)

{

    string text1 = "A";

    string text2 = "B";

    string text3 = "C";

    string text4 = text1 + text2 + text3;

    Console.WriteLine(text1);

}

 

//and now for a slightly different question and answer:

static void Main(string[] args)

{

    string a = "A" + "B" + "C" + "D" + "E" + "F" + "G";

    string b = "ABCDEFG";

}

 

take a look at the debug disassembly and you will see that both a and b are initialized with the same literal:
string a = "A" + "B" + "C" + "D" + "E" + "F" + "G";
00000029 mov eax,dword ptr ds:[0227307Ch]
0000002f mov edi,eax
string b = "ABCDEFG";
00000031 mov eax,dword ptr ds:[0227307Ch]
00000037 mov esi,eax

kick it on DotNetKicks.com   Friday, March 17, 2006 10:02:22 PM (Pacific Standard Time, UTC-08:00)  #    Disclaimer  |  Comments [0]  | 
 Tuesday, March 07, 2006

Does your new Dell high resolution LCD display graphics within Internet Explorer that look like this?


Your computer manufacturer has enabled a setting within IE that attempts to scale graphics to their original intended size by correcting for your wide aspect or high resolution display. You can turn it off with the following registry hack. Graphics will now appear smaller but clean.

REGEDIT4
[HKEY_CURRENT_USER\Software\Microsoft\Internet Explorer\Main]
"UseHR"=dword:00000000

Download the Reg files here:
http://download.binaryocean.com/IEUseHR.zip

kick it on DotNetKicks.com   Tuesday, March 07, 2006 10:54:21 AM (Pacific Standard Time, UTC-08:00)  #    Disclaimer  |  Comments [2]  | 
 Monday, February 27, 2006

This is a bit off topic:

My old Nokia 6xxx series phone gave me many years of service before the seal between the LCD and the outer plastic clear screen finally went. The phone collected lint from my pocket rendering it unreadable in direct sunlight. I could pop off the back and front covers and clean the screen but would only get a few days out of it. Maybe I needed to work on my laundering technique instead? Time for a new phone...

I have always wanted a Microsoft Windows Mobile Smartphone so I decided to give the Cingular 2125 a try. A phone that I could program with the CF and sync with all my Outlook contacts! To top things off, Cingular is currently offering their Media Net unlimited data plan for $20 per month so now I could even read my email. Seemed like a no brainer to me.

At first I really loved the phone. The display is bright and beautiful. The much talked about power button isn't really that bad. You just need to realize that the button is really just a bump on the hard plastic strip that runs across the top of the phone. To push it, push perpendicular to the plastic strip and not the faux button. The strip is attached and hinges slightly at the right hand side of the phone. The faux button is on the left and is more of a guide than anything else. I was able to set up the phone and sync to my back end Exchange server without much effort.

The Dark Side: After using the phone for a day, I found that my average to slightly large hands were just too big for those tiny keys. The phone is almost the same size as my previous Nokia but the screen takes up most of that real estate. I also found that about 35% of the time I would make the wrong selection with the little joy stick (another result of the large screen and small key area.) Lastly, the Media Net access was painfully slow. I was quickly regretting my choice.

I returned the phone and exchanged the 2125 for a Motorola RAZR which seemed like a much better fit for my fingers and hands. I also went with the RAZR because it is the same phone that my wife has and having a single set of chargers and connectors is nice. My only complaint with the phone is that you can't page in the address book and scrolling a contact line at a time is very slow.

One other minor complaint about the RAZR is that Motorola decided to orient the LCD (and front polarization) at 90 degrees to what is normally done. On most of the active LCDs that I have used, the screen gets brighter and darker as you change the angle of tilt by moving the top of the screen closer and further away from you but when you do this on the RAZR, the brightness remains relatively constant. On most LCDs as you move from left to right the brightness remains constant at least until you move way out to one side or the other. Again, my RAZR exhibits exactly the opposite behavior. I notice a subtle difference in the brightness of the image viewed by my left and right eyes. I am guessing that Motorola did this to better handle the "flip" aspect and thus the different vertical viewing angles of the phone?

If Motorola were to put Windows Mobile on the RAZR form factor, they would have a big hit.

kick it on DotNetKicks.com   Monday, February 27, 2006 9:24:19 AM (Pacific Standard Time, UTC-08:00)  #    Disclaimer  |  Comments [1]  | 
 Thursday, February 16, 2006

Just came across this little generic gem:

string[] input = { "1", "2", "3", "4", "5", "6", "7", "8", "9" };

int[] output = Array.ConvertAll<string, int>(input, delegate(string s) { return int.Parse(s); });

 

I have a number of web.config files that store lists of integers as comma separated strings. This is a clean way to convert it all to an int array. (It is in need of some exception handling.)

 

<appSettings>

      <add key="MachineIDs" value="44,3,43,566" />

</appSettings>

 

private int[] GetConfigIntArray(string key)

{

    string[] values  = ConfigurationManager.AppSettings[key].Split(',');

    return Array.ConvertAll<string, int>(values, delegate(string s) { return int.Parse(s); });

}

kick it on DotNetKicks.com   Thursday, February 16, 2006 10:46:59 PM (Pacific Standard Time, UTC-08:00)  #    Disclaimer  |  Comments [5]  |