@Robin , Welcome to Microsoft Q&A, you could try the following code to insert the picture to the word file and set the size of picture in the file.
object missing = System.Reflection.Missing.Value;
object name = @"C:\Users\username\Desktop\test111.docx";
object Range = System.Reflection.Missing.Value;
//Start Word and create a new document.
Word.Application oWord;
Word.Document oDoc;
oWord = new Word.Application();
oDoc = oWord.Documents.Open(ref name, ref missing, ref missing,
ref missing, ref missing, ref missing, ref missing, ref missing, ref missing, ref missing,
ref missing, ref missing, ref missing, ref missing, ref missing, ref missing);
//bool t = oWord.Selection.Find.Execute("You Can");
Word.Range range = oDoc.Paragraphs[3].Range;
//range.SetRange(range.Start, range.End - 10);
Word.InlineShape autoScaledInlineShape = range.InlineShapes.AddPicture(@"C:\Users\username\Desktop\W10.jpg");
autoScaledInlineShape.Width = 50;
autoScaledInlineShape.Height = 70;
oDoc.Save();
oDoc.Close();
Best Regards,
Jack
If the answer is the right solution, please click "Accept Answer" and upvote it.If you have extra questions about this answer, please click "Comment".
Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.