ASP.NET 4.0: Extra space above Menu in Chrome and Safari using Menu Control

In Visual Studio 2010 when creating a new ASP.NET Web Site or ASP.NET Web Application you get a shell for ASP.NET 4.0 web site with a menu using the ASP.NET 4.0 Menu Control. However in Google Chrome and Safari browsers the menu will show with some extra space above it. It took plenty of googling to find the answer since google is filled with solutions for Chrome problems in ASP.NET 2.0.
Finally – the solution for .NET Framework 4.0:

Add these lines to the Site.css file (in the Styles folder of your VS 2010 project)
[code lang=”css”]
/* Fix for extra space above menu in Chrome and Safari */
img[alt=’Skip Navigation Links’] {
display: none;

An alternative is to add SkipLinkText=”” to each menu item (have not tested this)

Thanks to MattyF for the solution

Search for text in multiple files

AstroGrep is a great free and open source tool for searching for a text string in multiple files. It is a single exe file, no installation needed. Requires .NET framework.

(I’m not involved in this tool in anyway, just came across it and thought I’d share/keep for future reference)

Get a Google Wave invite

I have been trying out Google Wave for a few days now and I have to say that I’m not that impressed with the user experience – it is not at all inutitive, this is obviously the type of program where you really have to read the manual! But I will give it some more time, read that manual, watch the instruction videos etc.

Anyway, I have some Google Wave invites so if you’re interested just comment here with your email and I will give away on a first come first serve basis.

Ps. I’m looking for a Voddler invite, anyone got one?

[Edit: I’m out of invites. Will post here again if I get new ones]

Fantastic News!

This isn’t technology related but since I have this blog how can I not post about it?

Two days ago my second daughter Alva was born. She’s a beautiful baby girl! On the photo she’s 10 hours old and “sitting” together with my other daughter Ebba who is 2+ years old. Some facts: Born Sunday 11 June, 5:19 AM CET, a beautiful sunny summer day. Weight 4120 grams, height 51 cm.

I think Sweden has one of the world’s most generous systems when it comes to letting the parents take time off work to care for their newborns. (I may be wrong because I admit I’m actually not familiar with how it works in that many other countries…)

Anyway, for starters the father gets two weeks paid leave from work, which is why my Out of Office message currently reads “I’m on paternity leave, will be back June 26” πŸ™‚
Parents also get 18 months of paid leave to divide between them. This means I’m going to have a loooong summer holiday. My wife will probably be home from work for a year and after that I plan on taking 6 months off. We did the same thing when we had Ebba and it was great spending that long time with your child!

DVD in Full Screen with Multiple Monitors in Windows XP

It’s not uncommon that friends ask me to help fix their computer problems. I’m happy to help but unfortunatly I’m not that good at fixing common hardware and OS problems, my knowledge of those things is just not good enough anymore – back in the good old days (I’m talking IBM PS/2, Token Ring, Windows 3.0 and OS/2) I could fix anything πŸ˜‰
Anyway, today I actually managed to fix something so I thought I’d brag a little about that…

A friend told me he had this problem that whenever he played a DVD on his computer it was played in full screen and there was no way he could access the control panel of the DVD player software (he had tried all the players he had installed incl. Real Player and Windows Media Player) or get back to the Windows XP Desktop. He used to hard reboot the computer until another friend told him he could use ALT+F4 to close the movie.

I started checking the most elementary things and after awhile I noticed in Display Properties that he had Multiple monitors enabled (but he only has one physical monitor).
I didn’t really know what to do so I activated (“attached”) the secondary monitor. I should not have done that because now all his monitor was showing was the secondary monitor – a blank screen with nothing on it but the background image.
Whatever I tried nothing showed up on the screen, I couldn’t get into the Display Properties again or any other program or menu – I suppose they all showed up on the primary monitor (and his one physical monitor only showed the secondary monitor).
So after a few hard resets I finally remembered to hit F8 like a maniac as Windows boots up and I got into the startup menu and I can select to restart using an old configuration.

Some time later I finally find the reason and the solution: His graphics card has two digital output ports and my friend has connected both his monitor’s digital and analogue (using an adapter) display cables to his card. So the graphics card and Windows recognize this as two monitors. Disconnecting the analouge cable solved his problem.

He shows me the installation instructions (this is a Fujitsu Siemens computer) and it sure looks like you should connect both the digital and analogue cables, and they even included the adapter to connect the analogue cable to the digital port. Not easy for him to know.

At the same time I also fixed another minor problem he had with his network: He keeps getting warnings that the network is not connected even though it seems to be working fine. Turns out he has two network connections in Windows. Reason and solution? Same as with the monitor – his Thomson ADSL modem allow the PC to be connected using both a standard Ethernet RJ45 cable and a USB cable, my friend connected using both πŸ˜‰

Programmer’s Frustration

I just wanted to share this great story by Damien Katz, a former programmer at Iris/Lotus. I first read it about a year ago and came across again today. It’s about Damien as a novice C++ programmer rewriting one of the core components of Lotus Notes/Domino – the formula engine, originally written by Ray Ozzie.

I used to work a lot with Lotus Notes and remember when the new Formula engine was released, it was a big thing. If you have had any programming experience and ever tried to do something with someone elses code I think you will enjoy this – even if you’ve never touched Lotus Notes. It’s a kind of a programmer’s “hero story”. Make sure you read the comment by Ray Ozzie too.

Bonus: Here’s a Lotus interview – from back in the days – about the new formula engine.

Ray Ozzie and Microsoft’s New Services Strategy

I just read this article in Fortune, headlined “Microsoft’s new brain”. It’s about Ray Ozzie but the real take aways for me were:

1) how Microsoft think about their new services strategy.

2) the report on how the new management at Microsoft work. I had understood that Ozzie played an important role but not that important.

Neither had I realized the vast amounts of money that needs to be put in to hardware and infrastructure investments. Some quotes:

“Just think about where there are windmills, dams, and other natural power sources around the world, and that’s where you’re going to see server farms,” he says.

“The people who could build a viable services infrastructure of scale,” he says, “are companies that have both the will and the capacity to invest staggering amounts of money – staggering amounts.” Think billions, many billions.

Google is rumored to have a million servers around the world and, according to a knowledgeable source, is already the top electricity user in at least one large U.S. state. Google would not comment.

Problem solved: FTP and Windows 2003 Firewall

Since I’m new to blogging I didn’t know how to use my own domain name with this blog. A quick Google revealed that the way it works is that I simply use Blogger as usual but whenever I publish anything it is published to my web server using FTP.

I have my own web server and currently do not use FTP so I had to set that up. I’m using Windows 2003 Server Enterprise Edition SP1 and I wanted to use the FTP server that comes with it (IIS 6). I have set up FTP on Windows before so I didn’t think it would be a problem, but that was before the Windows firewall…

After setting up configuring and starting my FTP server I had no problem to log on to it, but I got a timeout right away when the FTP client (I was simply using IE6 as my FTP client) tried to do the initial directory listing. Same thing when I tried to publish from Blogger. Using localhost on the server itself or using the console FTP client – ftp.exe – in Windows XP SP2 worked fine however.

I’ll skip all the Googling, MSDN search, trial and error and try to make a long story short:

I found out that there seems to be a problem with the Windows Firewall. On the Exceptions tab I had made an exception for FTP on TCP port 21 but as it turned out that did not work but I had to go to the Advanced tab, select my connection under Network Connection Settings and click the Settings button. From there check FTP Server and voìla, it works.

Why there is a difference between making the exception from the Exceptions tab or the Advanced tab I don’t know, probably a bug if you ask me. But right now I don’t care about that – I’m just happy that it’s working!