Actually, windows 98 can only effectivly use around 332mb ram. Anything over that it does become unstable.
Also, deleting the tmp or temp directory in the windows folder will not find all of the tmp files.
The best way to delete the tmp files is to go to start>find>files and folders
in the named type *.tmp and ensure that your hard drive(s) are in the look in and that find is set to look in all sub folders.
Do the search, then delete all of the files and empty the recycling bin.
Also go to the control panel>internet options. About in the middle is Temporary internet files, choose the delete button. In the box that pops up, tick the box for all offline content and hit ok.
If this still does not solve the problem, and you have troubleshooted the ram and it is fine, delete the pagefile.sys on the root directory by booting to the windows98 boot disk. Then reboot. If the swap file, pagefile.sys becomves fragmented or corrupted, it will give you the same errors about not running enough memory.