Word 2016 Using Sendkeys in Autoopen

Bobby Jennings 1 Reputation point

I would like to send a string to a word document when it opens.
But, sendkeys does not seem to work.

Here is my code.
Sub AutoOpen()
Selection.MoveDown Unit:=wdLine, Count:=10
Selection.MoveUp Unit:=wdLine, Count:=10
Call NavPaneSearch
SendKeys "Hi Mom"
End Sub

This should send "Hi Mom" to the newly open document, but it doesn't do it.

What will make this work?

{count} votes