Adds a text box to a drawing canvas. Returns a Shape object that represents the text box.
Sub NewCanvasTextbox() Dim docNew As Document Dim shpCanvas As Shape 'Create a new document and add a drawing canvas Set docNew = Documents.Add Set shpCanvas = docNew.Shapes.AddCanvas _ (Left:=100, Top:=75, Width:=150, Height:=200) 'Add a text box to the drawing canvas shpCanvas.CanvasItems.AddTextbox _ Orientation:=msoTextOrientationHorizontal, _ Left:=1, Top:=1, Width:=100, Height:=100 End Sub
The following arguments are required:
(Office.MsoTextOrientation) - The orientation of the text. Some of the MsoTextOrientation constants may not be available to you, depending on the language support (U.S. English, for example) that you have selected or installed.