but actually you have not permanently lost photo files from compact flash card. because, formatting any storage media like cf card will only erase the access permissions of files saved on it and mark the memory space as free so that new data can be saved there. thus, all the pictures will be still present on the card, until and unless new files takes up lost file space on cf card.

This is all lower case. Can you fix that?
But actually you have not permanently lost photo files from compact flash card. Because, formatting any storage media like CF card will only erase the access permissions of files saved on it and mark the memory space as free so that new data can be saved there. Thus, all the pictures will be still present on the card, until and unless new files takes up lost file space on CF card.