matlab - ActiveX control of Word. Select text and images -


this have done far:

word = actxserver('word.application');  document = word.documents.open('c:\documents , settings\kz7213\desktop\test.docx');  selection = word.selection;  selection.typetext('big finale');  selection.style='heading 1';  selection.typeparagraph;  fig1 = figure('visible','off'); plot([1 2 3 4 5],[4 1 3 5 7]);  print -dmeta  selection.paste;   selection.style='heading 1';  selection.insertcaption('figure','test figure 1'); %not working selection.style='captionstyle';  selection.typeparagraph; 

how can select previous entered text such "big finale" edit it, or select figure pasted selection. paste command in order make caption image?

possible solution in vba ms word:

'to find text     selection.find.execute findtext:="big finale", wrap:=wdwrapalways  'to select inline shape     activedocument.inlineshapes(1).select 

alternative solution find inlineshape(s) use .find.execute method following settings:

selection.find.execute findtext:="/", wrap:=wdwrapalways, matchwildcards:=true 

Comments

Popular posts from this blog

image - ClassNotFoundException when add a prebuilt apk into system.img in android -

I need to import mysql 5.1 to 5.5? -

Java, Hibernate, MySQL - store UTC date-time -