Portable application not showing in win32com browser, how to dispatch it?

huangapple go评论71阅读模式
英文:

Portable application not showing in win32com browser, how to dispatch it?

问题

这是一款便携软件,可与科学仪器通信。它是一款便携软件,可以将整个文件夹复制到任何电脑上的任何位置。

通过双击“.exe”文件,可以开始使用此软件与仪器通信。它具有一个类似于“portable.application”的ProgID,但在com浏览器中没有显示。

当我执行

win32com.client.Dispatch("portable.application")

出现错误

com_error: (-2147221005, 'Invalid class string', None, None)

我该如何调用此应用程序?我猜我需要以某种方式将应用程序注册到注册表中。

英文:

There is a portable software which communicates with a scientific instrument. It is a portable software, where one can just copy the whole folder to anywhere in any PC.

And by double clicking the '.exe' file, one can start to talk to the instrument using this software. It has a ProgID like "portable.application", but it is not shown in the com browser.

When I do

 win32com.client.Dispatch("portable.application")

The error is

com_error: (-2147221005, 'Invalid class string', None, None)

How can I dispatch this application? I guess I need to register the application to the registry somehow.

答案1

得分: 2

一种检查COM对象属性的方法是使用位于Python site-packages文件夹中的win32com\client目录下的combrowse.py

如果你要查找的portable.application未列出,那么无法访问该应用程序。

请查看以下链接,可能会有所帮助:

http://timgolden.me.uk/pywin32-docs/html/com/win32com/HTML/QuickStartClientCom.html

英文:

One way to check the attributes in a COM object is using the combrowse.py available on win32com\client in your python site-packages folder

Portable application not showing in win32com browser, how to dispatch it?

If the portable.application you're looking for isn't listed, you can't access that application.

Take a look at the following link that might help..

http://timgolden.me.uk/pywin32-docs/html/com/win32com/HTML/QuickStartClientCom.html

huangapple
  • 本文由 发表于 2020年1月3日 20:53:29
  • 转载请务必保留本文链接:https://go.coder-hub.com/59579000.html
匿名

发表评论

匿名网友

:?: :razz: :sad: :evil: :!: :smile: :oops: :grin: :eek: :shock: :???: :cool: :lol: :mad: :twisted: :roll: :wink: :idea: :arrow: :neutral: :cry: :mrgreen:

确定