Does anyone know how to switch between Word documents using Jacob?
The selection Dispath object is retrieved from the Application ActiveX object using something like
ActiveXComponent m_wordApp = new ActiveXComponent("Word.Application");
Dispatch selection = m_wordApp.getProperty("Selection").toDispatch()
but this seems to take no regard of the documents open. If you want to insert some text at the current selection for Document1 there doesn't seem to be any way to guarantee it. I've found that setting a selection Range on a document works fine: