word automation problem
- by daemonkid
I am trying open a word document for manipulation. However in the code below 'wordApp.Selection' is always null
object missing = System.Reflection.Missing.Value;
Word._Application wordApp = new Word.Application();
Word._Document aDoc =wordApp.Documents.Open(ref fPath1, ref missing, ref readOnly, ref missing, ref missing, ref missing, ref missing, ref missing, ref missing, ref missing, ref missing, ref isVisible, ref missing, ref missing, ref missing, ref missing);
Word.Selection selection = wordApp.Selection
Any ideas on how what I am missing here. Why is wordApp.Selection getting set as null.?
Thanks.