How to programmatically detect if a png file is corrupted using c# .NET?
<p>I have written a code that is saving some bitmaps in png format (using bitmap.Save() method). However for some unknown reason some of the images are saved as corrupted pngs so photoshop cannot open them.
I need to detect these pngs in my code rather than opening them one by one in the photoshop.</p>

<p>Can any one help me with this?
is there any way that I can read the created png and check if it is corrupted?</p>
