Dynamic Web TWAIN: Debugging with LogLevel

Step-By-Step Usage Guide for

In Dynamic Web TWAIN we have a property called LogLevel to catch detailed information when necessary. The property returns or sets the log level for debugging purpose.

Data type: Short

Syntax: ObjectName.LogLevel

Remark:

0 – The default value for LogLevel.
1 – More output information will be provided for debugging purpose

Step-by-step usage guide:

1. Starting by deleting the old log files located at:

v10~v12 C:\Windows\SysWOW64\Dynamsoft\DynamicWebTwain\ForChrome\log

v13+ C:\Windows\SysWOW64\Dynamsoft\DynamsoftService\log

For version 11.* or older, log file also would appear in
C:\Users\{USER NAME}\AppData\LocalLow\Dynamsoft\

2a. Set LogLevel to enable debug mode for all end users:

Change the source code.  Set the LogLevel to 1 in the initialization function of Web TWAIN control, like Dynamsoft_OnReady.

function Dynamsoft_OnReady() {
  DWObject = Dynamsoft.WebTwainEnv.GetWebTwain('dwtcontrolContainer');
  ...
  DWObject.LogLevel = 1;
  ...
}

2b. Set LogLevel to enable debug mode on specific client machines (don't forget to restart Dynamic Web TWAIN service after the change):

On client-side, change Log level from 6 to 14 in DWTConfiguration.ini at v10~v12 C:\Windows\SysWOW64\Dynamsoft\DynamicWebTwain\ForChrome\DWTConfiguration.ini
v13+ C:\Windows\SysWOW64\Dynamsoft\DynamsoftService\DSConfiguration.ini

3. Reproduce the issue that you encountered

4. Collect the log files in the directories below

v10~v12 C:\Windows\SysWOW64\Dynamsoft\DynamicWebTwain\ForChrome\log

v13+ C:\Windows\SysWOW64\Dynamsoft\DynamsoftService\log

For version 11.* or older, log file also would appear in
C:\Users\{USER NAME}\AppData\LocalLow\Dynamsoft\

5. Zip the log files and sent them to support[at]dynamsoft.com.

NOTE:

1. For 32-bit Windows machines, the \ForChrome\ folder is under C:\Windows\system32\Dynamsoft\DynamicWebTwain\ 2. For Windows 10 OS, enabling the debug mode will slow down the performance of the scan page. To avoid the slowness in this situation, you can add the webtwainservice.exe to the exclusion list of Windows Defender.

Add the webtwainservice.exe to Settings > Update &Security > Windows Defender > Exclusions > Processes

3. To get a better performance of the scan page, please turn off the debug mode in daily use.

In Dynamic Web TWAIN we have a property called LogLevel to catch detailed information when necessary. The property returns or sets the log level for debugging purpose.

Data type: Short

Syntax: ObjectName.LogLevel

Remark:

0 – The default value for LogLevel.
1 – More output information will be provided for debugging purpose

Step-by-step usage guide:

1. Start by deleting the old log files located at the below directory.

Select Go > Applications > Dynamsoft > WebTwain > {installed version No.} > log

2a. Set LogLevel to enable debug mode for all end users:
Change the source code.  Set the LogLevel to 1 in the initialization function of Web TWAIN control, like Dynamsoft_OnReady.

function Dynamsoft_OnReady() {
  DWObject = Dynamsoft.WebTwainEnv.GetWebTwain('dwtcontrolContainer');
  ...
  DWObject.LogLevel = 1;
  ...
}

2b. Set LogLevel to enable debug mode on specific client machines(don't forget to restart Dynamic Web TWAIN service after the change):

On client-side, change log level from 6 to 14 in DWTConfiguration.ini Select Go > Applications > Dynamsoft > WebTwain > {installed version No.} > DWTConfiguration.ini

3. Reproduce the issue that you encountered

4. Collect the log files in the directories below

Select Go > Applications > Dynamsoft > WebTwain > {installed version No.} > log
Select Go > Go to Folder…, a prompt will appear: type /var/log in the box and you’ll find system.log file.

5. Zip the log files and sent them to support[at]dynamsoft.com.

NOTE:

To get a better performance of the scan page, please turn off the debug mode in daily use.

In Dynamic Web TWAIN we have a property called LogLevel to catch detailed information when necessary. The property returns or sets the log level for debugging purpose.

Data type: Short

Syntax: ObjectName.LogLevel

Remark:

0 – The default value for LogLevel.
1 – More output information will be provided for debugging

Step-by-step usage guide:

1. Download DebugView here, and unzip it locally.

2. Set the LogLevel to 1 in the intialization function of Web TWAIN control, like Dynamsoft_OnReady

function Dynamsoft_OnReady() {
            DWObject = Dynamsoft.WebTwainEnv.GetWebTwain('dwtcontrolContainer');
            ...
            DWObject.LogLevel = 1;
            ...
            }

3. Run Dbgview.exe.

4. Reproduce the issue you encountered with the ActiveX Edition. The DebugView will record detailed information during the process, as shown below.

5. Please click on Save to save the log file and send it to support[at]dynamsoft.com.

NOTE:

1. To get a better performance of the scan page, please turn off the debug mode in daily use.

In Dynamic Web TWAIN we have a property called LogLevel to catch detailed information when necessary. The property returns or sets the log level for debugging purpose.Data type: Short

Syntax: ObjectName.LogLevel

Remark:

0 – The default value for LogLevel.
1 – More output information will be provided for debugging

Step-by-step usage guide:
1. Start by deleting the old log files located at the below directory.

/opt/dynamsoft/WebTwainService/log

2a. Set LogLevel to enable debug mode for all end users:
Change the source code.  Set the LogLevel to 1 in the initialization function of Web TWAIN control, like Dynamsoft_OnReady.

function Dynamsoft_OnReady() {
  DWObject = Dynamsoft.WebTwainEnv.GetWebTwain('dwtcontrolContainer');
  ...
  DWObject.LogLevel = 1;
  ...
}

2b. If you only want to enable the debug mode on specific client machines:

On client-side, change log level from 6 to 14 in DWTConfiguration.ini in /opt/dynamsoft/WebTwainService directory

3. Reproduce the issue that you encountered

4. Collect the log files in the directories below

/opt/dynamsoft/WebTwainService/log

5. Zip the log files and sent them to support[at]dynamsoft.com.

NOTE:

To get a better performance of the scan page, please turn off the debug mode in daily use.