-
-
Notifications
You must be signed in to change notification settings - Fork 327
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
naps2.sdk - problem with scanner in citrix environment #412
Comments
Can you attach the debuglog from the NAPS2 exe for comparison? Are you scanning using the worker (NAPS2.Sdk.Worker.Win32) or by running your main process as 32-bit? (You can also try the other to see if it makes a difference.) |
The debug log is attached. We have tried both. Both reacted in the same way. |
Tobias is a colleague of mine, we can do a remote session together under a Citrix session to analyze/fix the bug. |
A couple more things you could try to narrow down the difference between the SDK and the NAPS2 application:
|
I apologize for my late response. “Old DSM” works without problems in NAPS2. If I start a Windows Forms application and call |
Yes, you'll need to call |
Sorry for my stupid questions. But unfortunately I'm not very familiar with Windows Forms. When starting the application, I registered the load event to get the handle.
Then I click on a button to load the scanner and scan as in the example. I have tried both, using an async method and also invoking it. Example async button click:
Example Invoke:
But in both cases I get the error message “This can only be created on the Windows Forms UI thread”. |
You can try this with the latest SDK version (1.1.3) as I've made some improvements that might help. |
Describe the bug
I have tried to access a scanner via redirected Twain in Citrix using the NAPS2.Sdk and the examples. However, the process hangs and the scanner is then blocked via Twain.
Logging in first Scan:
Scanning with ScanDevice { Driver = Twain, ID = PaperStream IP SP-1125, Name = PaperStream IP SP-1125 }
Scan source: Duplex; bit depth: Color; dpi: 150; page size: 8.5x11 in
Using TWAIN DSM: C:\WINDOWS\twain_32.dll
NAPS2.TW - Opening session
NAPS2.TW - StateChanged (to 3)
NAPS2.TW - Finding source
NAPS2.TW - Opening source
NAPS2.TW - Name: PaperStream IP SP-1125; Manu: FUJITSU; Family: PaperStr; Version: 3.32 3.32.0.1361 Apr 23 2024; Protocol: 2.4
NAPS2.TW - StateChanged (to 4)
NAPS2.TW - Configuring source
NAPS2.TW - Enabling source
NAPS2.TW - StateChanged (to 5)
-> from here it does not go any further - it hangs
Logging in second Scan:
Scanning with ScanDevice { Driver = Twain, ID = PaperStream IP SP-1125, Name = PaperStream IP SP-1125 }
Scan source: Duplex; bit depth: Color; dpi: 150; page size: 8.5x11 in
Using TWAIN DSM: C:\WINDOWS\twain_32.dll
NAPS2.TW - Opening session
NAPS2.TW - StateChanged (to 3)
NAPS2.TW - Finding source
NAPS2.TW - Opening source
NAPS2.TW - Name: PaperStream IP SP-1125; Manu: FUJITSU; Family: PaperStr; Version: 3.32 3.32.0.1361 Apr 23 2024; Protocol: 2.4
NAPS2.TW - Finishing with error
Error: NAPS2.Scan.Exceptions.DeviceException: TWAIN error: MaxConnections
Additional context
When using the Naps2 console application and the Naps2 exe, the scanner works without any problems.
The text was updated successfully, but these errors were encountered: