This project has moved. For the latest updates, please go here.

About win8 X64 control scaner ,has error at openDSM

Jul 16, 2014 at 4:59 PM
hello ,Saraff
my application run at vs2010 win8 X64 .net4.0

if first scan,has a info "no midea",dont have anything.
at second scan,at openDSM my software crash.

can u answer me,way?

PS: I check u source,this error has a point,is don
t run AcquireCompleted
Jul 16, 2014 at 5:03 PM
i find at u twian32 OPENDSM
[
            if (this.Parent != null)
            {
                this._hwnd = this.Parent.Handle;
            }
            if (this._dsmEntry != null)
            {
                MessageBox.Show(this._dsmEntry.GetType().ToString());
            }

****at this area crash! TwRC _rc = this._dsmEntry.DsmParent(this._appid, IntPtr.Zero, TwDG.Control, TwDAT.Parent, TwMSG.OpenDSM, ref this._hwnd);
            if (_rc == TwRC.Success)
            {
                this._TwainState |= TwainStateFlag.DSMOpen;
]
Coordinator
Jul 16, 2014 at 6:14 PM
Edited Jul 16, 2014 at 6:24 PM
Hello, JohnnyLeung!
See this topic
And update the code to the latest revision. The above code missing in my project.
Jul 16, 2014 at 6:30 PM
hello,saraff
i early see this topic
i used 1.0.10.365

and if scaner has paper ,its ok
only scaner don
t have paper,after aleart a not have paper message,don`t have anything.
and i see the request message is NOT.....NOT....NOT....

if i free memory,all application is closed.
Jul 16, 2014 at 6:31 PM
and same soruce code run on win XP,is ok
Coordinator
Jul 16, 2014 at 6:41 PM
Hello, JohnnyLeung!
Show the exception stack trace.
Jul 16, 2014 at 6:46 PM
i debug now ,i used 1.0.11.375.
dont have any exception stack trace.
software is close.....
and can
t try
Jul 16, 2014 at 6:53 PM
r u have any sns software? skype?QQ?

this question is ....hard
Jul 16, 2014 at 6:54 PM
在 Saraff.Twain.Twain32.OpenDSM()
在 zcst_rz.TWain.Saraff_T..ctor()
在 zcst_rz.Db.ScanerOP.getInitScaner_ZY()
在 zcst_rz.Controls.ZzsRz.btn_fscan_Click(Object sender, EventArgs e)
在 System.Windows.Forms.Control.OnClick(EventArgs e)
在 System.Windows.Forms.Button.OnClick(EventArgs e)
在 System.Windows.Forms.Button.OnMouseUp(MouseEventArgs mevent)
在 System.Windows.Forms.Control.WmMouseUp(Message& m, MouseButtons button, Int32 clicks)
在 System.Windows.Forms.Control.WndProc(Message& m)
在 System.Windows.Forms.ButtonBase.WndProc(Message& m)
在 System.Windows.Forms.Button.WndProc(Message& m)
在 System.Windows.Forms.Control.ControlNativeWindow.OnMessage(Message& m)
在 System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m)
在 System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)
在 System.Windows.Forms.UnsafeNativeMethods.DispatchMessageW(MSG& msg)
在 System.Windows.Forms.Application.ComponentManager.System.Windows.Forms.UnsafeNativeMethods.IMsoComponentManager.FPushMessageLoop(IntPtr dwComponentID, Int32 reason, Int32 pvLoopData)
在 System.Windows.Forms.Application.ThreadContext.RunMessageLoopInner(Int32 reason, ApplicationContext context)
在 System.Windows.Forms.Application.ThreadContext.RunMessageLoop(Int32 reason, ApplicationContext context)
在 System.Windows.Forms.Application.Run(Form mainForm)
在 zcst_rz.Program.Main()
Coordinator
Jul 16, 2014 at 6:59 PM
Exception is thrown or not?
Try use Saraff.Twain.Sample2.exe and Saraff.Twain.Sample2_x86.exe
Jul 16, 2014 at 7:21 PM
o ,sample2_X86,can run ,no error
Jul 16, 2014 at 7:27 PM
u sample2_X86 compiling platform is X86 only?
Coordinator
Jul 16, 2014 at 7:31 PM
Hence, the problem is with the scanner driver x64. You can try to build the main assembly (exe-file) for x86 platform.
Marked as answer by JohnnyLeung on 7/16/2014 at 11:36 AM
Jul 16, 2014 at 7:37 PM
thanks ,your tools is very useful to me.