Error message: HTTP process error

Symptom:
When you upload images using any of the HTTPUploadThroughPost*** methods of Dynamic Web TWAIN, you may receive the following error messages:

Cause:

1. The write permission is not granted to the specified directory on the web server.

2. The action page is incorrect or returns something from the web server.

3. The Port for uploading is not right.

4. The size of the images you are trying to upload is beyond the maximum allowed size set by the server. Dynamic Web TWAIN uses a special way to see if an image is uploaded and processed successfully by server. If the server returns 0 bytes, this indicates success. Otherwise, this indicates failure. In other words, when the uploaded image is processed successfully, the action page on the server should not return anything.

Solution:

1. Make sure the users who are uploading have permission to write images to the specified directory on the web server. (For example, give "Write" permission to the Authenticated Users.)

2. Please check the response string returned from the HTTP server. The response string can help you figure out the cause of the process error. You can get this string by using the HTTPPostResponseString property. Click here for more information about the property.

3. Set the Port with the property HTTPPort.
(For example: If the URL for the scan page is "http://localhost:3253/....", you need to set the port to 3253).

We recommend you get the Port and Server value this way:

var strHTTPServer = location.hostname;
DWObject.HTTPPort = location.port==""?80:location.port;

NOTE:
If you set the IfSSL property to true, please note you must set a secure port for the HTTPPort property. For example,

DWObject.IfSSL = true;
DWObject.HTTPPort = 443;

4. Please reset the maximum transferable data size:

If you are using ASP:

If you are using IIS 6:
1) Start -> Run , type "cmd"
2) Go to "C:\Inetpub\AdminScripts" by typing: cd C:\Inetpub\AdminScripts 3) To view max request entity allowed:
cscript adsutil.vbs get w3svc/AspMaxRequestEntityAllowed

If you are using IIS 7:
1) Start -> Run , type "InetMgr" to open the IIS 7 Manager
2) {Your WebSite}->Feature View->ASP->Limits Properties
3) Set "Maximum Requesting Entity Body Limit" to a larger value like "1000000"

To set the max request entity allowed:
cscript adsutil.vbs set w3svc/AspMaxRequestEntityAllowed 1000000 (You can change the value by yourself.)

If you are using ASP.NET, you can change the value in the following line in the "Web.Config" file.
<httpRuntime maxRequestLength="1000000"/> (You can change the value by yourself.)

If you are using ASP.NET on IIS 7, you might need to add the below line as well:
<requestLimits maxAllowedContentLength="300000000" />. For more info, please click here. Below is a simple sample:

<?xml version="1.0" encoding="UTF-8"?>
<configuration>
<system.web>
<httpRuntime executionTimeout="3000"  maxRequestLength="102400"/>
<compilation debug="true" />
</system.web>
<system.webServer>
<security>
<requestFiltering>
<requestLimits maxAllowedContentLength="300000000" />
</requestFiltering>
</security>
</system.webServer>
</configuration>

If you are using PHP, you can change the value in the following line in the php.ini file:
upload_max_filesize = 2M (You can change the value by yourself.)

Also, you can send the screenshot of the response string to support@dynamsoft.com so that we can help you pinpoint the cause of the issue.

Is this page helpful?

Leave a Reply

Your email address will not be published.