It is really irritating situation for users when photos get lost from Pentax camera.However I have also suffered from this problem many times.Whenever I uses to access photo I come to various error message that file is unknown , unrecognized format , it does not exists. I thought that it was not possible to recover . Lastly I would be able to overcome from this problem with the help of photo recovery software.
http://freeware.pentaxphotorecovery.net