Type

CheckBoxControl.Type property

获取 Forms 2.0 控件的类型。

public override Forms2OleControlType Type { get; }

例子

显示如何改变 CheckBox 控件的状态。

Document doc = new Document(MyDir + "ActiveX controls.docx");

Shape shape = (Shape)doc.GetChild(NodeType.Shape, 0, true);
CheckBoxControl checkBoxControl = (CheckBoxControl)shape.OleFormat.OleControl;
checkBoxControl.Checked = true;

Assert.AreEqual(true, checkBoxControl.Checked);
Assert.AreEqual(Forms2OleControlType.CheckBox, checkBoxControl.Type);

也可以看看