Modifica

Condividi tramite


IInfoPathDataImporterFields.GetControls(IEnumUnknown) Method

Definition

Gets a collection of IInfoPathViewControl objects for each control in the view.

public:
 void GetControls([Runtime::InteropServices::Out] mshtml::IEnumUnknown ^ % ppEnumUnkControls);
public void GetControls (out mshtml.IEnumUnknown ppEnumUnkControls);
abstract member GetControls :  -> unit
Public Sub GetControls (ByRef ppEnumUnkControls As IEnumUnknown)

Parameters

ppEnumUnkControls
mshtml.IEnumUnknown

An mshtml.IEnumUnknown collection of controls in the view.

Remarks

Use the GetControls method of the IInfoPathDataImporterFields interface to return a collection of IInfoPathViewControl objects. Each object in the collection corresponds to a control in the view of the form. Each control has various properties you can evaluate or set, like the read-only DataType and InputScopes(IntPtr, UInt32, IEnumString, String) properties, and the read/write Value property.

Use these properties in conjunction with the data from the import source to import data into an InfoPath form. The following controls in the view are enumerated (if present):

Text BoxPlainText
Rich Text BoxRichText
Drop-Down List BoxDropDown
Combo BoxComboBox
List BoxListBox
Date PickerDTPicker_DTText
Check BoxCheckBox
Option ButtonOptionButton
Bulleted ListListItem_Plain or ListItem_formatted
Numbered ListListItem_Plain or ListItem_formatted
Plain ListListItem_Plain or ListItem_formatted
PictureInlineImage or LinkedImage
Ink PictureInkPicture
File AttachmentFileAttachment

The following controls are not enumerated (excluded from the enumeration):

Section
Optional Section
Repeating Section
Repeating Table
Horizontal Repeating Table
Master/Detail
Expression Box
Vertical Label
Button
Hyperlink
Scrolling Region
Choice Group
Repeating Choice Group
Choice Section
Repeating Recursive Section
Custom Controls (ActiveX)
Multiple-Selection List Box

For more information about programmatically importing data into an InfoPath form, see the InfoPath Developer PortalMicrosoft Office Developer Center.

Applies to