We have a separate Nikon dSLR
Forum setup for dSLR models like your D50. So, I've moved this thread there for you.
Chances are, the FAT (File Allocation Table) on the card is corrupted. Reformatting using a camera's menu choice for Format (not a PC) will usually solve that. I always reformat my cards prior to every reuse to minimize any potential corruption issues. That way, the card always starts out with a fresh FAT, just the way the camera expects it (since you're using it to format your card).
If you can't read the card to get your images from it, I'd suggest that you download and install this software for the operating system you're using (Windows, Mac, Linux). It's free. You'll see a download menu choice on the left side of the main page. Then, just click on the desired operating system to download it.
Use a card reader if possible, and select your memory card from the list of media it finds (hard drives, memory cards, etc.), and give it a place to save the photos to on your hard disk when you are asked Where to Save Recovered Files (it defaults to saving recovered files in subfolders under Photorec, where the software is installed on your hard drive, but you can change it to something else if desired). Note that this product does not retain the original file names (but, you may not care about that), since it ignores the file allocation table entirely.
Don't worry about changing any of the other options. Just leave everything else at the defaults (Partition type of Intel, file types to recover, etc.) and it will try to recover any files that haven't been overwritten yet (and don't try to do anything like take more photos or you may overwrite some of them).
Here's a page showing you how to use this software:
There are some other free programs around that do a pretty good job in most cases., too. Here's one example, and it also has a nice Graphical User Interface. I usually prefer photorec. But, if you're not comfortable with a text based interface, you may want to try this one first instead.
After you get your images from the card (and make sure you can see the larger images, not just the thumbnails), I'd make sure to format the card before using it again, using the camera's menu choice for format.