我需要自动化通过 java 连接到 PowerDesigner 以从存储库中提取模型的过程。我已经使用 OLE 自动化 JavaProxy 文档来配置该过程。
尝试运行时,我收到此错误:
线程“主”java.lang.NoSuchMethodError 中的异常:org.eclipse.swt.internal.ole.win32.COM.CoCreateInstance(Lorg/eclipse/swt/internal/ole/win32/GUID;IILorg/eclipse/swt/internal/ ole/win32/GUID;[I)I 在 com.sybase.stf.powerdesigner.PdCommon.Application.start(Application.java:57) 在 com.sybase.stf.powerdesigner.PdCommon.Application.(Application.java:31) ) 在 com.sybase.stf.powerdesigner.PdCommon.Application.getInstance(Application.java:42) 在 OOM.src.createOOM.CreateOOM.CreateAndDisplayOOM(CreateOOM.java:37) 在 OOM.src.createOOM.CreateOOM.main(创建OOM.java:28)
版本:
- 电源设计器 - 16.5.5.0
- 日食 4.18
支持罐子:
- pdj2com_16.5.5.jar
- org.eclipse.swt.win32.win32.x86_64_3.115.100.v20201202-1103.jar
上述问题已解决 谢谢!
现在,我在与以下问题再次连接时遇到了麻烦。
org.eclipse.swt.SWTException:无法执行操作。结果 = -2137456383 (com.sybase.stf.powerdesigner.com.COMException: COM 失败 [HRESULT: 0x80990101]) 在 org.eclipse.swt.ole.win32.OLE.error(OLE.java:345) 在 com.sybase .stf.powerdesigner.com.COMException.raiseOnFail(COMException.java:83) 在 com.sybase.stf.powerdesigner.com.IDispatchEx.raisingInvoke(IDispatchEx.java:231) 在 com.sybase.stf.powerdesigner.PdCommon.IApplication .CreateModel(IApplication.java:84) 在OOM.src.createOOM.CreateOOM.createOOM(CreateOOM.java:68) 在OOM.src.createOOM.CreateOOM.CreateAndDisplayOOM(CreateOOM.java:42) 在OOM.src.createOOM。 CreateOOM.main(CreateOOM.java:28) 原因:com.sybase.stf.powerdesigner.com.COMException: COM 失败 [HRESULT: 0x80990101] at com.sybase.stf.powerdesigner.com.COMException.raiseOnFail(COMException.java :88) ...
我无法在网上找到任何解决方案。请帮我解决这个问题。提前致谢。