GetWrapperShape
Returns a shape in which the form is placed to control the position and size of the fixed size form frame.
The null value will be returned for the inline forms.
Inherited from ApiFormBase.GetWrapperShape.
Syntax
expression.GetWrapperShape();
expression - A variable that represents an ApiTextForm class.
Parameters
This method doesn't have any parameters.
Returns
Example
Access the surrounding shape that holds a fixed-size form field in a document.
// How do I get the container shape around a text field to adjust its appearance in a document?
// Style the outer frame of a text field by reaching its wrapper shape in a document.
let doc = Api.GetDocument();
let textForm = Api.CreateTextForm({"key": "Personal information", "tip": "Enter your first name", "required": true, "placeholder": "First name", "comb": true, "maxCharacters": 10, "cellWidth": 3, "multiLine": false, "autoFit": false});
let paragraph = doc.GetElement(0);
paragraph.AddElement(textForm);
textForm.ToFixed(10 * 240, 2 * 240);
let shape = textForm.GetWrapperShape();
let stroke = Api.CreateStroke(36000, Api.CreateSolidFill(Api.RGB(255, 111, 61)));
shape.SetOutLine(stroke);