BadDocumentFileType Example VB

In this example, when the BadDocumentFileType event fires, the associated file is overwritten.

Private Sub ImgEdit1_BadDocumentFileType(ByVal Page As Long, ErrorOut As Boolean,
 SkipPage As Boolean, OverWritePage As Boolean)
    'If an attempt is made to rewrite a file type which is not
    'supported for write, the file would be converted to TIFF
    'and overwritten.
    ErrorOut = False
    Overwrite = True
End Sub