The image file also grows when doing other updates like deskew, despeckle, add annotations.
Below is the information you requested:
ltkrn13n.dll Version: 13.0.0.12
----------------------------- delete snippet start -----------------------------
FOR I = 1 TO NoPagesToDel
PageNoToDelete = StartingPageNo
oiretcode = w_hiddenimagewindow.ole_lead.object.DeletePage(MultiPageFileName , PageNoToDelete)
IF oiretcode <> 0 THEN
setpointer(Arrow!)
MessageBox("Delete Page:Error" , "Error Code " + string(oiretcode))
return -1
END IF
NEXT
----------------------------- delete snippet end -----------------------------
----------------------------- deskew snippet start -----------------------------
retvalue = long(ole_lead.object.deskew())
IF retvalue <> 0 THEN
setpointer(Arrow!)
MessageBox("Deskew Image :Error", "Error Code " + string(retvalue))
return
END IF
ole_lead.object.ForceRepaint()
// force a save
ImageFileName = isMultiPageFileName
IF ImageFileName = "" THEN
setpointer(Arrow!)
MessageBox("Save Image :Error", "Error retrieving image file name " )
return
END IF
imagefileformat = 29
ole_lead.object.savepage = gwscanframe.iicurpagenoindoc
// Save all annotation in wang format
ole_lead.object.AnnSaveTag(TRUE , FALSE )
retvalue = ole_lead.object.save( ImageFileName , imagefileformat , 0 , 0 , 2 )
IF retvalue <> 0 THEN
setpointer(Arrow!)
MessageBox("Save Image :Error", "Error Code " + string(retvalue) + " " + ImageFileName )
return
END IF
----------------------------- deskew snippet end -----------------------------
----------------------------- despeckle snippet start -----------------------------
retvalue = long(ole_lead.object.despeckle())
IF retvalue <> 0 THEN
setpointer(Arrow!)
MessageBox("Despeckle Image :Error", "Error Code " + string(retvalue))
return
END IF
ole_lead.object.ForceRepaint()
// force a save
ImageFileName = isMultiPageFileName
IF ImageFileName = "" THEN
setpointer(Arrow!)
MessageBox("Save Image :Error", "Error retrieving image file name " )
return
END IF
imagefileformat = 29
ole_lead.object.savepage = gwscanframe.iicurpagenoindoc
// Save all annotation in wang format
ole_lead.object.AnnSaveTag(TRUE , FALSE )
retvalue = ole_lead.object.save( ImageFileName , imagefileformat , 0 , 0 , 2 )
IF retvalue <> 0 THEN
setpointer(Arrow!)
MessageBox("Save Image :Error", "Error Code " + string(retvalue) + " " + ImageFileName )
return
END IF
----------------------------- despeckle snippet end -----------------------------