Bartender print时出现错误(COM组件未授权)的解决办法

来源:互联网 发布:php获取post数据 编辑:程序博客网 时间:2024/04/28 11:11

在调用Bartender的程序的时候(Bartender.Application btApp=new Bartender.Application())的时候有时会出现如下错误信息:

Sys.WebForms.PageRequestManagerServerErrorExceptionRetrieving the COM class factory for component with CLSID{B9425246-4131-11D2-BE48-004005A04EDF} failed due to the following error80070005.

解决办法如下:

1:打开Administrative Tools->EventViewer->System,查看error event如下图:

2:双击Error行,看到如下图所示的error msg,此error msg表示COM组件未被NETWORK SERVICE授权


3:查看对应的IIS应用程序池里面的权限设定,发现使用的账号是Network Service,如截图所示:


4:打开AdministrativeTools->Component Services,找到COM Security,按照下图所示把NETWORK SERVICE的权限加进去即可。


0 0