共用方式為


_XDocument3.InputParameters 屬性

取得 InputParameterCollection 物件,其中包含使用 /InputParameters 命令列選項指定的任何輸入參數,或在 URL 中使用查詢參數指定的任何輸入參數。

**命名空間:**Microsoft.Office.Interop.InfoPath
**組件:**Microsoft.Office.Interop.InfoPath (於 microsoft.office.interop.infopath.dll 中)

語法

'宣告
<DispIdAttribute(55)> _
ReadOnly Property InputParameters As InputParameterCollection
'用途
Dim instance As _XDocument3
Dim value As InputParameterCollection

value = instance.InputParameters
[DispIdAttribute(55)] 
InputParameterCollection InputParameters { get; }

屬性值

包含輸入參數的 InputParameterCollection 物件。

備註

輸入參數是由一組或多組以 & 字元分隔的成對名稱/值組成;您可以在從命令列開啟表單範本或使用 /InputParameters 命令列選項開啟批次檔時指定這些成對的名稱/值。從 URL 開啟表單範本時,也可以使用查詢參數來指定輸入參數。

範例

在下列範例中,會使用下列語法從命令列開啟 InfoPath 表單範本:

infopath.exe "C:\User Forms\DeptReport.xsn" /InputParameters "Dept=Accounting"

string vDept = (_XDocument3)thisXDocument.InputParameters["Dept"];
Dim vDept As String = 
   DirectCast(thisXDocument, _XDocument3).InputParameters("Dept")

請參閱

參考

_XDocument3 介面
_XDocument3 成員
Microsoft.Office.Interop.InfoPath 命名空間