Skip to main content

Team,

Let’s say if I want to replace text within tables in MS Word, and not use keystrokes, what is the best way to go about this in AA?

 

 

@Hiren Savla Word is not really structured so keystrokes for find/replace is usually the right answer. You could build a PowerShell script that opens the Word file and performs the replaces, too, but you're not far ahead of just using keystrokes.

OLE could be used if you double click on the tables if they were inserted from another source, like Excel, but I would not bet on that working well. This is because OLE links are easily broken in Windows and you would probably still have to use keystrokes in the embedded application. 

Have you considered the reverse? Creating the table in Excel then OLE linking it to the Word doc? Still probably not a great idea. 😅

If you REALLY wanted to push the envelope, DOCX files are zip files containing XML. You could parse and update the XML and update the zip (DOCX) file... not an easy option but doesn't use keystrokes or OLE. 


Team,

Let’s say if I want to replace text within tables in MS Word, and not use keystrokes, what is the best way to go about this in AA?

 

 

Use Word Package with Bookmarks

Insert bookmarks inside table cells in your Word template

  • Use AA’s Microsoft Word Package > Insert Text at Bookmark action

  • This allows targeted replacement without keystrokes


@Hiren Savla have any of these suggestions helped? Please mark best answer if they did!