public void CreateForm()
{
//ExStart
//ExFor:TextFormFieldType
//ExFor:DocumentBuilder.InsertTextInput
//ExFor:DocumentBuilder.InsertComboBox
//ExSummary:Builds a sample form to fill.
DocumentBuilder builder = new DocumentBuilder();
// Insert a text form field for input a name.
builder.InsertTextInput("", TextFormFieldType.Regular, "", "Enter your name here", 30);
// Insert two blank lines.
builder.Writeln("");
builder.Writeln("");
string[] items = new string[]
{
"-- Select your favorite footwear --",
"Sneakers",
"Oxfords",
"Flip-flops",
"Other",
"I prefer to be barefoot"
};
// Insert a combo box to select a footwear type.
builder.InsertComboBox("", items, 0);
// Insert 2 blank lines.
builder.Writeln("");
builder.Writeln("");
builder.Document.Save(MyDir + @"\Artifacts\DocumentBuilder.CreateForm.doc");
//ExEnd
}