Music to Install Windows By

October 22, 2009 – 21:12

Windows 7 Home PremiumWindows 7 turned up in the post today. The red box is Visual Studio 2008 which is there to show that the boxes have a similar profile to the old style hard cases.

I have been running the Beta since it was first available to the general public, and I have had Windows 7 Business at work for a couple of weeks now. Bought Windows 7 Home Premium for about £45 from Tesco. One copy for the main PC which I will probably re-build at Christmas and one copy for the laptop which is re-built now. Scott Hanselman described Vista as an operating system that stabs you in the eye a thousand different ways, I would have to agree with that. Windows 7 is different, things work how you think they should and don’t seem to randomly break when you least expect it.

As for the title of this blog post, I have mostly been installing Windows 7 to Vampire Weekend which Kev introduced me to. The track M79 seems to have taken some inspiration from the Sailor’s Hornpipe better known as the Blue Peter theme tune, seems to cut off just at the moment I am expecting it to carry on into the main part of the music. Maybe there is a Mike Oldfield link in addition to the lyrical Peter Gabriel link.

If I am moved to over the course of the next couple of week I shall try and point out some of the new features available in Windows 7 that are cool. For the time being try the following hold down Alt, while still holding down Alt press “Alt Gr” (The other side of the space bar) then press Tab. For some reason you get the old XP style Alt-Tab window. Utterly pointless?

Adjusting Selections in CodeRush Xpress

October 16, 2009 – 20:30

I found this function totally accidentally when I knocked my mouse into a key when something interesting popped up on Twitter. I happened to have a variable selected like so:

Variable Selected in Visual Studio

The key that I knocked was the Number Pad “+” key, and it expanded the selection like this:

VariableSelectedPlus1

As any self respecting Systems Administrator would do I wondered if doing exactly the same thing repeatedly would have equal or compound effects.

VariableSelectedAgainAgain

Strangely enough it worked, the selection will continue to expand selecting increasingly larger sections of code. The reverse works as well if you press the Number Pad “-” key the selection will be reduced.

WhatHappened

As I was looking for documentation on this function; I found that you could use the CamelCase select function to start selections off using Ctrl+Shift+Left (or Ctrl+Shift+Right) this will take your selection from the current cursor position to the next upper case character to the left (or right). This can be coupled with the Number Pad “+” to expand your selection from a variable to an expression, to a line then a block. Neat!

Each of these discoveries was announced with a handy little popup in the bottom right hand corner of the viewport telling me what happened, and if relevant what function was suppressed.

I am going to make a concerted effort to spend my lunch break watching some more videos on DevExpress’ training site. I got 10 minutes today and watched what appeared to be footage from a launch event or a conference which was interesting but didn’t really teach me anything specifically.

Find Files in CodeRush Xpress

October 12, 2009 – 13:27

As I mentioned in my previous entry I have started using DevExpress’s CodeRush Xpress. It is a free cut down version of CodeRush that I heard about in an episode of .NET Rocks. I have wanted add something to my Visual Studio development experience and I can’t justify the cost of either Resharper or CodeRush at the moment. There has been quite a bit of discussion about Resharper vs. CodeRush and in my experience most people I have spoken to love one and hate the other.

I hope to be able to write a series of posts about some of the features found in CodeRush Xpress which I hope will clarify their purpose and use in my mind and maybe help someone find the function they are looking for.

QuickFileNavigationAbouFirst off “Quick File Navigation”, this is a search function for locating a file by file name, I am finding it increasingly useful when looking through patches as it allows me to very quickly jump to a file name. Particularly as I am trying to move my projects to a one class per file so if I can remember the class name I can find the code file very quickly.

The “Quick File Navigation” dialog is accessible through the keyboard short cut Ctrl+Alt+F. Typing will filter the list box by the name of the file matching anywhere in the filename including the extension.

An additional feature for those who like me use CamelCase in their file names; if you enter your filter terms in capital letters it will search for capitalized words, in order within file names. Thus entering “AW” into the search box will also bring up the AboutWindow.cs in the above solution.

Combining the above with the Ctrl-G keyboard shortcut in Visual Studio 2008 to go to a specific line we can do the following to go to line 162 in ShipLoadoutSelectWindow.cs:

Ctrl+Alt+F  →  S,L,S,W  →  Ctrl+G →  1,6,2

DevExpress have a great training video on their tv.devexpress.com sub site.

Ctrl+Alt+F → S,L,S,W → Ctrl+G → 1,6,2

Long time no blog…

October 10, 2009 – 13:21

I had been intending to post up all sorts of bits of news about life, driving, programming and cats but it didn’t happen. I have been busy which is good, however it doesn’t leave very much room for blogging. This post is going to be one really quick catch up entry to try and get me back into the swing of it.

I finally passed my driving test at the beginning of the summer, it was my fourth try and I passed with three minors which was a great feeling… since then I have driven once, as part of PassPlus, which didn’t really feel vastly different, although it was more enjoyable knowing that I didn’t have a test coming up. Catherine and I have decided to wait for a bit before we get a car so we can assess what Catherine will need in terms of model and adaptations in a car to allow her to get the most out of it.

Zoe and KerrySadly Kerry, Zoe’s sister died a few months after Zoe, as a family we weren’t ready to lose her, although it wouldn’t have been fair to let her suffer an operation that might not help anyway, so my parents decided it was best to have her put down. My brother and I got a chance to say good bye to her, she wasn’t her normal self and was in a lot of pain. We are all very sad.

In programming land I spent last weekend learning SQL Server Integration Services and this weekend I plan to get into Analysis Services. Have been doing some utility programming at work to automate some of the file server operations we do, I am trying to automate as much as possible using something similar to duck tape programming to free me up to do more programming to create a more unified and friendly framework for managing the school network. Started using CodeRush Xpress both at home and at work.

In sys. admin world I have been continuing to use and learn Windows 7, I now have RTM installed at work still waiting for RTM to arrive at home on or around the 22nd. Been reading and listening to various resources surrounding Windows 2008 R2 particularly some excellent podcasts on RunAs radio.

Running through the rain

May 5, 2009 – 20:04

I don’t send on these Internet “chain letters”, as in general I don’t think people want to get generic forwarded and forwarded e-mails from me, they would probably prefer me just to e-mail them to ask them a question, favor or just to say hello. I do like this one though, it has a fair point and it makes it well. I have removed what I suppose would be described as the postamble from the bottom, as it doesn’t work for blog  posts.

A little girl had been shopping with her Mom in Checkers. (For those that do not know Checkers is a Supermarket store in S.A.) She must have been 6 years old, this beautiful red haired, freckle faced image of innocence. It was pouring outside. The kind of rain that gushes over the top of rain gutters, so much in a hurry to hit the earth it has no time to flow down the spout. We all stood there under the awning and just inside the door of Checkers.

We waited, some patiently, others irritated because nature messed up their hurried day. I am always mesmerized by rainfall. I got lost in the sound and sight of the heavens washing away the dirt and dust of the world. Memories of running, splashing so carefree as a child came pouring in as a welcome reprieve from the worries of my day. The little voice was so sweet as it broke the hypnotic trance we were all caught in “Mom, let’s run through the rain,” she said. “Let’s run through the rain!” She repeated. “No, honey. We’ll wait until it slows down a bit,” Mom replied.

This young child waited about another minute and repeated: “Mom, let’s run through the rain,” “We’ll get soaked if we do,” Mom said. “No, we won’t, Mom. That’s not what you said this morning,” the young girl said as she tugged at her Mom’s arm. “This morning? When did I say we could run through the rain and not get wet?”

“Don’t you remember? When you were talking to Daddy about his cancer, you said, ‘If God can get us through this, he can get us through anything!” The entire crowd stopped dead silent. I swear you couldn’t hear anything but the rain. We all stood silently. No one came or left in the next few minutes.

Mom paused and thought for a moment about what she would say. Now some would laugh it off and scold her for being silly. Some might even ignore what was said. But this was a moment of affirmation in a young child’s life. A time when innocent trust can be nurtured so that it will bloom into faith.

“Honey, you are absolutely right. Let’s run through the rain. If GOD let’s us get wet, well maybe we just needed washing,” Mom said. Then off they ran. We all stood watching, smiling and laughing as they darted past the cars and yes, through the puddles. They held their shopping bags over their heads just in case. They got soaked. But they were followed by a few who screamed and laughed like children all the way to their cars.

And yes, I did. I ran. I got wet. I needed washing.

Circumstances or people can take away your material possessions, they can take away your money, and they can take away your health. But no one can ever take away your precious memories… So, don’t forget to make time and take the opportunities to make memories everyday. To everything there is a season and a time to every purpose under heaven.

I think it was the penultimate paragraph that made me think the most, all Christians have had that “saving” experience, but we need washing clean every morning because our acts and experiences don’t match up with God’s expectations.

New Webhost

May 3, 2009 – 17:13

I have transfered to a new web-host, if you are seeing this message it has worked. That is all I have to say about it.

Fixing EVEMon’s Crashy C++ DLLs

April 18, 2009 – 20:22

I have been working on EVEMon for about two months now, taking on the responsibility of committing changes to the trunk, fixing bugs and adding new features. As a project I have been involved for several years submitting bug fixes and little features, it was down to my experiences with EVEMon that I decided to implement Subversion and Trac at work.

Unfortunately the first time it came to me to be responsible for a release, it seemed to go terribly wrong. The updated installer worked fine, and it seemed initially there were no problems with the updated code base. However BattleClinic shortly went a little mad with bug reports similar to this one:

EVEMon Version: 1.2.7.1283
.NET Runtime Version: 2.0.50727.1434
Operating System: Microsoft Windows NT 6.0.6001 Service Pack 1
Executable Path: “C:\Program Files\EVEMon\EVEMon.exe”

System.IO.FileLoadException: Could not load file or assembly ‘lgLCDNETWrapper, Version=2.0.0.0, Culture=neutral, PublicKeyToken=null’ or one of its dependencies. The application has failed to start because its side-by-side configuration is incorrect. Please see the application event log for more detail. (Exception from HRESULT: 0×800736B1)
File name: ‘lgLCDNETWrapper, Version=2.0.0.0, Culture=neutral, PublicKeyToken=null’ —> System.Runtime.InteropServices.COMException (0×800736B1): The application has failed to start because its side-by-side configuration is incorrect. Please see the application event log for more detail. (Exception from HRESULT: 0×800736B1)
at EVEMon.LogitechG15.Lcdisplay.Dispose(Boolean bDisposing)
at EVEMon.LogitechG15.Lcdisplay.Finalize() in D:\EVEMon\EveMon.LogitechG15\Lcdisplay.cs:line 70

For those who are not familiar the above is the crash report generated by EVEMon when a .NET exception is unhandled. lgLCDNETWrapper is the C++ library EVEMon uses to communicate with the Logitech G15. A similar error was generated for EVEMons other C++ component the window relocator.

Tonto Auri quickly spotted that the problem was something to do with the re-compiled C++ DLLs and switching the new DLLs with those from an older package resolved the problems. Whilst this was a fix, I wasn’t willing to just revert the changes and give up on the changes we had made to the G15 library, additionally I was concerned that we had not made changes to the window relocation code and that was causing at least one person a problem.

Quite a bit of searching about with Google and Stack Overflow resulting in finding these two little gems of information:

These two posts basically gave me the tools and the knowledge to fix EVEMon’s problems.

First I made the sudden (and “facepalm”) realization that EVEMon deployed the Visual Studio 2005 Redistributable; we had moved to Visual Studio 2008 SP1 about a month before the release of 1.2.7. I confirmed this with the Dependency Walker utility, by walking lgLCDNETWrapper.dll I was able to confirm that version 9.0.21022.8 of the Microsoft CRT Library (Microsoft.VC90.CRT) would be required.

The next trick was figuring out which re-distributables to deploy with EVEMon to ensure the end user would have all the dependencies required to use all of the features; frustratingly it seems that Microsoft only bundles the latest version of the re-distributables with Visual Studio 2008 and that was version 9.0.30729.1 which was not going to cut it.

Enter Nuonsofts excellent article providing a step by step guide on adding the required compiler flags to ensure the latest version of the CRT was bound. I did find a nice GUI resource editor that was capable of getting the manifests out in XN Resource Editor which made the process a little faster.

A little bit of hacking later the updated Visual Studio 2008 SP1 CRT DLLs and manifest file were deployed to the Microsoft.VC90.CRT folder within the EVEMon program files directory as the VC80 CRT libraries were in the past and the two C++ projects were setup to bind to the latest version with the _BIND_TO_CURRENT_CRT_VERSION=1 preprocessor definition.

A bit more poking arround with XN Resource Editor and Dependency Walker showed we were now in a far better position to have a working copy of EVEMon in the hands of our end users.

Zoe

April 17, 2009 – 21:28

We got Zoe and her sister Kerry in the summer of 2000 before I left for University, it had been a few years since our last cat, Emma, had died and my parents decided it was time to have a cat (or cats as it turned out) in the house again.

Zoe (2000 - 2009)

I love cats, despite being allergic to them, so I gladly sat in the back of the car with the two kittens in their travel box, the as yet unnamed kitten Zoe looked a bit pitiful and couldn’t stay standing up I was worried about her, although as it turns out she made the journey just fine.

As they had just been separated from their mother they were nervous little things, Zoe hid in the corner of the conservatory, Kerry explored a little. I felt so sorry for them I took my sleeping bag and slept in the conservatory with them. During the night Kerry decided to get down the end of the sleeping bag and meow at my feet, Zoe who was more timid settled for sitting near by.

I don’t know why but Zoe seemed happy for me to hold her, I used to carry her round the room moving her in the direction that she turned her head, she quickly cottoned on and took the opportunity to sniff out the parts of the room she was unable to find under her own power; as long as we kept moving she was happy to stay in my arms.

Sadly, Zoe had to be put down yesterday (Thursday). I won’t go into the details as this is not how I want to remember her, I am glad I got to see her one last time a couple of weeks back before leaving for Spring Harvest. We are all going to miss her personality and affection.

Bye Bye Zoe.

Driving Test #2

April 16, 2009 – 17:42

Well another day, another driving test and another fail. I had hoped to say that this was a pass day today but it was not to be. I think the nerves got the better of me, I was okay for most of it although my throat kept drying up.

This test actually came out much worse than last time, again I had two serious faults, however more than twice as many minor faults with 14. It was a bit of a shock to me as I had realized I had made some minor mistakes here and there but had not spotted the major faults.

I won’t go into the minor faults, as they are too numerous to enumerate and honestly I can’t even pinpoint what I did wrong, I was focusing on the task at hand and have since totally forgotten the majority of the test itself.

Serious Fault #1 – Meeting a car in the road
This was one of the serious faults from my last test, I got a minor in the same area on this test too. Fundamentally I think it is a judgment problem on my part, I see a which has priority on the opposite side of the road I don’t seem to judge very accurately, I think perhaps in future I need to yield to them regardless of my judgment.

Serious Fault #2 – Road position
I cut across the lanes on a roundabout basically, I don’t even remember doing it and apparently I hadn’t done it on previous roundabouts, perhaps it was because it was the end of the test, and I had a lapse in concentration – although I do appreciate that is all it takes for someone to get hurt or worse.

I have re-booked for the end of May, at which point we will see what happens on Driving Test #3.

Nerves

April 16, 2009 – 9:24

The nervousness is really manifesting itself this time round despite taking my hay fever medication last night I am sneezing this morning, I think it is just the nerves. I woke up with a headache, the Paracetamol hasn’t really helped that much I am hoping it is going to clear as I head into town to sit in a coffee shop to relax a bit.

I feel nervous about taking the test, although neither outcome has any real consequences other than spending a bit more money and having it hanging over me for a few more weeks.