Make sure you are receiving a IP address from the router, and that both machines can see it.
Win98 computer:
Start -> run
Type in "winipcfg"
In the dialog box, you should have a couple sets of numbers, we are concerned about 3 of them, IP Address, Gateway, and DNS.
Your IP should look like 192.168.0.100 or similar. Not a 167.28.230.1 or similar.
Your gateway should be similar to your IP, 192.168.0.1
and your DNS should have some form of a IP. The router gets that from your ISP, and gives it to your computers.
Now that we have this information, go to start -> run. type in "command"
type in "ping 192.168.0.1" (or what ever your gateway address is.)
you should have something like this:
C:\>ping 192.168.2.1
Pinging 192.168.2.1 with 32 bytes of data:
Reply from 192.168.2.1: bytes=32 time<10ms TTL=64
Reply from 192.168.2.1: bytes=32 time<10ms TTL=64
if it says no response, your router may be bad.
For the Windows XP, It is almost the same as Win98, but instead of running winipcfg, right -click "my network places", go to properties. Double click "Local area network" then click on the support tab. it should be almost the same as the windows 98 box.
If you do not have an IP address, try releasing & renewing it. On win98, in winipcfg there is a button for it. on WinXP click "repair".
Hope this helps!