المساعد الشخصي الرقمي

مشاهدة النسخة كاملة : Error in WIA Scanning IMage on IIS Project



C# Programming
01-26-2010, 01:20 PM
i made web application to scan pages from scanner and worked well but when i made the project on IIS it is not work well and get me this problem

Description: An unhandled exception occurred during the execution
of the current web request. Please review the stack trace
for more information about the error and where it originated in the code
Exception Details: System.UnauthorizedAccessException: Creating
an instance of the COM component with CLSID {850D1D11-70F3-4BE5-9A11-77AA6B2BB201}
from the IClassFactory failed due to the following
error: 80070005. ASP.NET is not authorized to access the requested resource.
Consider granting access rights to the resource to the ASP.NET request identity.
ASP.NET has a base process identity (typically {MACHINE}\ASPNET on IIS 5 or Network Service on IIS 6) that is used if the application is
not impersonating. If the application is impersonating via
identity impersonate="true, the identity will be the anonymous user (typically IUSR_MACHINENAME)
or the authenticated request user.
To grant ASP.NET access to a file, right-click the file in Explorer,
choose "Properties" and select the Security tab.
Click "Add" to add the appropriate user or group. Highlight the ASP.NET account,
and check the boxes for the desired access.Source Error:
Line 26: int x = 0;
Line 27:
Line 28: CommonDialogClass class1 = new CommonDialogClass();
Line 29: Device d = class1.ShowSelectDevice(WiaDeviceType.UnspecifiedDeviceType, true, false);
Line 30: if (d != null)

please any one know the Answer please reply to me quickly i need this now