Not-So-Frequently Asked Questions

This document contains a number of questions that aren't asked of me very often but to which I need to remember the answers anyhow.

This so-called FAQ will never get close to being comprehensive, there is no particular order to the questions, and it's mainly for my own use, but you're welcome to the answers if you can use them.


Q: How do I fix corrupted Windows desktop icons?

Delete the existing icon cache and create a new one.

First, delete the hidden file ShellIconCache from the system directory. From a command prompt, type the following commands:

    attrib -h %SystemRoot%\ShellIconCache
    erase %SystemRoot%\ShellIconCache

Next, reboot the system.

Some users have reported that more than one reboot is necessary on some systems.


Q: How do I reset a Gateway AnyKey keyboard?

Press Alt + Ctrl + Suspnd Macro.


Q: What's that Perl script I was thinking about to fix newlines?

When run on a UNIX system, this script removes carriage-returns from text files created on DOS/Windows systems. When run on a Windows system, it inserts the blasted things in order to make Windows applications happy.

    open (FILE, $ARGV[0]) or die "Cannot open $ARGV[0]";
    while ($line = <FILE>) {
        $line =~ s/\r//;
        $line =~ s/\n//;
        print "$line\n";
    }

Q: How do I fix file associations in Windows?

Here is one of several possible solutions:

  1. Start Windows 95 Explorer or Windows NT Explorer (not to be confused with Internet Explorer) and select a directory that contains the files whose associations you want to change.
  2. Click on one of the files to highlight it.
  3. Hold down the Shift key and click the file with the right mouse button. A popup menu appears.
  4. Select Open With.... A dialog box appears with a list of applications.
  5. Highlight the application you wish to associate with the file type.
  6. Make sure the Always use this program to open this type of file check box is checked.
  7. Click OK.

Q: Where are the Gnome login screen graphics defined in Red Hat Linux?

For Red Hat Linux 6, the logo for the background screen (usually a Red Hat logo) is supplied as an argument to /usr/bin/xsri in /etc/X11/xdm/Xsetup_0.

For Red Hat Linux 7, the logo is specified in /etc/X11/xsrirc.

The logo for the login dialog (usually a Gnome logo) is specified as the Logo entry in the [Greeter] section of /etc/X11/gdm/gdm.conf.


Q: What does SV: mean when I see it at the beginning of the Subject: line of a newsgroup message?

It means essentially the same thing as RE: in Swedish, Danish, and Norwegian. It's an abbrevation of the word "svar."


Q: How can I list the fields of a Java object?

This subroutine will do the trick:

public static void dumpFields (Object obj)
{
    Class c = obj.getClass ();
    java.lang.reflect.Field[] f = c.getDeclaredFields ();
    int i;

    for (i = 0; i < f.length; i  ) {
        try {
            System.out.println (f[i].getName ()   ": "   f[i].get (obj));
        }
        catch (java.lang.IllegalAccessException e) {
            System.out.println (e);
        }
    }
}

Q: What does QED mean?

QED is an abbreviation for the Latin phrase "quod erat demonstrandum," or "which was to be proven."

It also stands for quantum electrodynamics.


Add a FAQ to the list (Most visitors are encouraged to use the Contact form instead.)

Retrieve the FAQ data file (encoded text)


Last update: 17 Feb 2000 -- (Copyright) -- (Contact)