An I.T. Problem Shared . . .

A blog of problems . . . and solutions

LCD monitor flickering saga

We just purchased a new LCD screen to use on an Acer Aspire 5535 laptop. When we connected the screen to the laptop there was an annoying flickering on the screen. It wasn’t that the screen was blacking out, more list horizontal scan lines flickering all over the screen.

The flickering seemed to be worst when there was keyboard or mouse activity so we initially thought that maybe the wireless keyboard and mouse were causing interference with the new monitor. We switched to a wired keyboard and mouse but still had the same problem.

We then swapped monitors with another PC but the problem stayed with the Acer laptop so the screen itself was fine. The laptop’s internal screen was fine but the external monitor was still flickering. We then spent several hours download and installing all the latest drivers on the laptop. W even updated the BIOS but still the screen flickered.

Different screen resolutions and refresh rates made little difference. The flickering varied but was always there. Then we had a breakthrough! – we noticed that when we disconnected the laptop’s power supply the flickering stopped. Faulty power supply we decided, having another power supply nearby we switched power supplies but still the flickering was there. So we tried another laptop with the Acer Aspire 5535′s power supply (the other laptop was also an Acer and the output of the two power supplies matched exactly!!) and had no flickering at all so the problem wasn’t the power supply but the laptop itself.

So we have a laptop which runs perfectly on its own but when attached to an external monitor and only when running on mains power the external monitor flickers.

Then whilst talking to a friend with an electronics background he suggested that the cause could be a ground loop between the laptop and the monitor. So I opened up the monitor’s 3 pin plug and disconnected the earth wire (as the monitor costs less and is easier to replace than the laptop!) and voila! the flickering was cured.

So it seems that the cause may be a badly designed power circuit in the laptop. I don’t know if there’s any kind of filtered sockets or plugs that would prevent a ground loop occurring and the fix I’ve used should be used with caution (seek professional advice if you’re at all unsure!) but it works for us.

Deleting Microsoft SQL Server 2000 from Windows 7 Sync Center

If you have to install Microsoft SQL Server 2000 on Windows 7 you’ll find that Windows Sync Center automatically starts at Windows startup. Opening Sync Center will show that Microsoft SQL Server 2000 has been automatically added and cannot be deleted.

To remove this sync partnership you need to edit the registry key HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\SyncMgr\Handlers

Find the branch that refers to Microsoft SQL Server and delete it. Sync Center should then not start up again at reboot (unless you have have other Sync Partnerships).

Accessing localhost on Vista/Windows 7

After installing WAMP on Windows Vista we came across a problem where we cannot access the default website using http://localhost – The name just doesn’t seem to resolve.

For some reason in Vista and Windows 7 localhost doesn’t work out of the box. To get it working you have to add this line to the c:\windows\system32\drivers\etc\hosts file:

127.0.0.1      locahost

Now the hosts file is a Windows system file so the only way Windows will allow you to edit the file is if you do it as Administrator. To do this click Start and type CMD in the search box, when Windows shows cmd.exe right-click it and click run as administrator then when the DOS box opens type:

edit c:\windows\system32\drivers\etc\hosts

Then add the 127.0.0.1 localhost line and save and close the file.  Then localhost should work as it did in XP.

Beware Vista Junction Points!

We’ve been having a few issues when copy files on Vista PCs. It started when we copied a ‘My Documents’ folder from an XP PC into a user’s documents folder on a Vista PC. We looked in the documents folder and found that the ‘My Pictures’ folder in the ‘My Documents’ folder on the XP PC wasn’t there on the Vista machine even though we’d copied the whole folder.

Looking closer we found that everything in the ‘My Pictures’ folder had been moved to \users\<user>\pictures on the Vista PC during the copy. Reading up it became clear that with Vista Microsoft change the location of many of the application data and user data folders and to minimise application compatibility due to this Vista uses junction points which are hidden redirects to the new folders. That way applications can look for the old folder that XP would use and be transparently redirected to the new location.

One of these junction points for example points \documents and settings\<user>\application data to \users\<user>\appdata

So care has to be taken when copying files and folders as they don’t always end up where you’d expect them to be. Another problem is that some junction points are cyclic – we found this out by trying to copy the whole system drive of a Vista PC onto a backup disk using nothing but Robocopy. It got to the ‘Application Data’ junction point and just got into a loop copy it over and over again into itself resulting in the destination drive having and endless Application Data\Application Data\Application Data\Application Data\Application Data\Application Data\Application Data\Application Data\Application Data\…. path!

The problem can be avoided by using the /XJD switch when using Robocopy.

PHP Mail() Function Problem on Windows Server

We recently had a problem trying to send email using the PHP Mail function on Windows 2003 Server. When we tried to send mail we just got an error message:

PHP Warning: mail(): SMTP server response: 501 5.5.4 Invalid Address

We were trying to add a ‘friendly’  name to the from header of the email in the format: 

$headers .= ‘From:  Name <address@domain.com>’. “\r\n”;

We found that PHP running on Windows doesn’t parse these headers correctly (see http://www.php.net/manual/en/function.mail.php ) so the fix was to change to:

$headers .= ‘From:  address@domain.com’. “\r\n”;

Which gets the mail to send but doesn’t allow us to use ‘friendly’ names.