Error using invoke method to execute script (in Catia)
4 ビュー (過去 30 日間)
古いコメントを表示
I am trying to run a script created in Catia, in the VB language, using the invoke command in Matlab, however this results in an error. The original commands in VB (which run correctly) are:
Sub CATMain
Dim params()
CATIA.SystemService.ExecuteScript "C:\Users\ABCXYZ\Documents\MATLAB\TestCase\VirtGage", 1, "GetAxis.CATvbs", "CATMain", params
End Sub
The equivalent Matlab method however does not work. It is written as follows:
catia = actxserver('catia.application');
feature('COM_SafeArraySingleDim', 1);
params = {};
SystemService=get(catia,'SystemService');
invoke(SystemService,'ExecuteScript','C:\Users\ABCXYZ\Documents\MATLAB\TestCase\VirtGage',1,'GetAxis.CATvbs','CATMain',params);
The Matlab command window output is as follows:
Error using Interface.catia_application.SystemService/invoke
Invoke Error, Dispatch Exception:
Description: ExecuteScript(C:\Users\ABCXYZ\Documents\MATLAB\TestCase\VirtGage, GetAxis.CATvbs, CATMain)
Internal error
Other similar invoke commands have worked. I am wondering if there is any way for this to work, and why the "description" line in the Matlab command window output misses out the variables 1 and params?
0 件のコメント
回答 (0 件)
参考
カテゴリ
Help Center および File Exchange で Logical についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!