I posted the following a few weeks ago on another forum and have had no
response, so am trying again here.
--------------------------------------------------
I've got a Windows Form control that is using Twain to scan documents and
which works fine in a windows application using a couple of different
scanners.
I am now trying to get this hosted and running in IE6 for our intranet app
but am running into problems. Basically, the control works in so far as it
can communicate with the scanner and detects when it is switched on/off and
connected/disconnected and I can interrogate and set the capabilities of the
scanner as well. If the scanner is switched off or I try and set an
incorrect capability it throws an
error, which tells me that it is communicating (initially at least) with the
scanner
When I debug the control in IE, it appears to initiate the scan sequence and
runs through to the point where it should then pass control to a function
named
PreFilterMessage (it implements IMessageFilter.PreFilterMessage) which then
should pass control to the scanner and return the image.
Unfortunately, before it gets to this point it just finishes and returns
control back to
the app. No exceptions are thrown.
The only hint that something is wrong is when I check the event log and see
that the aspnet_wp.exe process has stopped unexpectedly, but this gives me
no
further clue as to where the problem lies.
I assume it has something to do with the ImessageFilter interface but am not
sure how to go about tracking the problem down and resolving it.
The assembly has been strong named and granted full trust.
I am developing on a Win2K(SP4) machine running IIS 5.0. Development
environment is VS 2003.