I am writing a C# application using VS2010 and .Net Framework 4.0 that merges 2 TIF image files at a time that represents the front image and back image of a particular check by calling a function titled ProcessImage in the attached .txt file.
Thus, ProcessImage merges, for ex: check #1, Front image of a check WITH check #1 the Back image of a check ->
into check #1 Front/Back image of a check.
ProcessImage is called from a loop, and merges 2 compressed TIF check images at a time into 1 TIF image from a directory.
The resulting TIF image is very large in size. I am running out of disk space in the directory because the application is processing thousand of check images that were compressed and each time I write out a compressed check, it is no longer compressed.
Once all the TIF images have been merged, I then process the 2nd set of statements in the attached .txt file that compresses all the merged check images.
What I would like to do is rewrite my code so that each time ProcessImage is called for a particular check to merge, this function merges the 2 check images into 1 check image file AND THEN this function calls the second set of statements in the attached .txt file to compress the newly created merged check image file.
Currently my application only calls the 2nd set of statements after all the checks have been merged and it loops through all the merged checks to compress them. The FOR EACH process should be removed from this set of statements since it should only process 1 check.
I want to revised this second function so that it only compresses the check that was just processed by the function ProcessImage.
Do you know a way to process the attached 2 functions together in the .txt file so that they are performed, one after the other, each time the application calls ProcessImage?