Answer to "Why won't my Nikon D5100 won't detect my sd card?"I have a Nikon D70 that came to me cheap because it wouldn't recognize the compact flash memory card, I fixed this by spraying a little electronic switch cleaner into the card bay and into the card socket, now works every time. So far my D5100 hasn't had any problems but if it does it will get the same treatment.
Answer to "Getting a format error in both on and off positions"I had the same problem with a D70 and found that spraying the pins inside the camera and the sockets on the card with an electronic contact cleaner then working the card in and out several times stopped the problem,it appears the contacts tarnish and do not make a very good contact with the card.
Answer to "Getting a format error in both on and off positions"I found the problem that causes "FOR" and "CHR" to show and stop the camera working is dirty contacts from the card to the camera, I lightly sprayed electronic contact cleaner on the pins in the camera and the card sockets then plugged the card in and out 10 times, then make sure the card is formatted to "FAT" and all works, at least my has ever since.