No method 'TypeText' with matching signature found for class
11 views (last 30 days)
Show older comments
>> gen_Word_report
No method 'TypeText' with matching signature found for class
'Interface.00020975_0000_0000_C000_000000000046'.
Error in gen_Word_report (line 42)
actx_word.Selection.TypeText(cell2mat(req_text(i2,1)));
Above is the error I get when using the activeX functionality in MatLab to create a Word document. Here is the weird thing, it works just fine for 12 out of 13 uses of the very same script. However, on this one use it always fails at the same point after several minutes of creating the word document.
Anyone have an idea on how to begin troubleshooting this?
0 Comments
Answers (1)
Simone Lojeck
on 25 Apr 2019
I received the same error and found this posting searching for solutions. I'm adding a comment to help anyone who finds this in the same way I did.
As I've said I received the same error in a similar situation: code runs w/o error for several iterations then fails on a specific case.
I did some step by step debugging and found that the text I was sending the selection.TypeText command on the iteration w/error was indeed different. It was expecting a text string (in my case {text}), however I was sending it an empty string ({[]}), which caused the error. I fixed this and the script no longer failed.
I'd recommend seeing exactly what input is being sent to the TypeText cmd.
0 Comments
See Also
Categories
Find more on Data Type Conversion in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!