Shapes.AddTextbox Method
Creates a text box. Returns a Shape object that represents the new text box.
Namespace: Microsoft.Office.Interop.Excel
Assembly: Microsoft.Office.Interop.Excel (in Microsoft.Office.Interop.Excel.dll)
Syntax
'Declaration
Function AddTextbox ( _
Orientation As MsoTextOrientation, _
Left As Single, _
Top As Single, _
Width As Single, _
Height As Single _
) As Shape
'Usage
Dim instance As Shapes
Dim Orientation As MsoTextOrientation
Dim Left As Single
Dim Top As Single
Dim Width As Single
Dim Height As Single
Dim returnValue As Shape
returnValue = instance.AddTextbox(Orientation, _
Left, Top, Width, Height)
Shape AddTextbox(
MsoTextOrientation Orientation,
float Left,
float Top,
float Width,
float Height
)
Parameters
Orientation
Type: Microsoft.Office.Core.MsoTextOrientationRequired MsoTextOrientation. The orientation of the textbox.
Left
Type: System.SingleRequired Single. The position (in points) of the upper-left corner of the text box relative to the upper-left corner of the document.
Top
Type: System.SingleRequired Single. The position (in points) of the upper-left corner of the text box relative to the top of the document.
Width
Type: System.SingleRequired Single. The width of the text box, in points.
Height
Type: System.SingleRequired Single. The height of the text box, in points.
Return Value
Type: Microsoft.Office.Interop.Excel.Shape