Java stopped developing Java 1.6 for Windows 98 & earlier.
Last reported compatible version is update 7.
1. Download this version:
Archive: Download Java Platform Standard Edition (Java SE) 6u5 & choose the
JRE version.
2. (a) Use your Add/Remove Programs Control Panel to remove all versions of Java.
(b) Run this utility & click on Registry section:
Crap Cleaner to clean registry.
(c) Then install the above version.
Do NOT install this version of java without uninstalling the other version first.