This documentation is archived and is not being maintained.

InlineShapes.AddPicture Method

Adds a picture to a document.

Namespace:  Microsoft.Office.Interop.Word
Assembly:  Microsoft.Office.Interop.Word (in Microsoft.Office.Interop.Word.dll)

InlineShape AddPicture(
	string FileName,
	ref Object LinkToFile,
	ref Object SaveWithDocument,
	ref Object Range


Type: System.String
Required String. The path and file name of the picture.
Type: System.Object%
Optional Object. True to link the picture to the file from which it was created. False to make the picture an independent copy of the file. The default value is False.
Type: System.Object%
Optional Object. True to save the linked picture with the document. The default value is False.
Type: System.Object%
Optional Object. The location where the picture will be placed in the text. If the range isn't collapsed, the picture replaces the range; otherwise, the picture is inserted. If this argument is omitted, the picture is placed automatically.

This method returns a Shape object that represents the picture and adds it to the InlineShapes collection.