Quantcast
Channel: Saraff.Twain.NET
Viewing all articles
Browse latest Browse all 419

New Post: MessageBox doesn't show in the AcquireCompleted event

$
0
0
Hello guys!

I does not understand what is happening with my code .. If i put MessageBox out of AcquireCompleted event it work's!

I'm doing something like this:

class Scanner{
    public Scanner(){
               _twain.AcquireCompleted += new EventHandler(complete);
    }

    private void complete(object sender, EventArgs e){
             if (
            MessageBox.Show(
            "Successful!", "Information",
            MessageBoxButtons.OK,
            MessageBoxIcon.Information,
            MessageBoxDefaultButton.Button1) == DialogResult.OK);
    }
}

Thank's everybody!

Peter.

Viewing all articles
Browse latest Browse all 419

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>