共用方式為


VersionUpgradeEvent.SolutionVersion 屬性

取得 Microsoft Office InfoPath 表單範本的版本號碼。

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

語法

'宣告
<DispIdAttribute(2)> _
ReadOnly Property SolutionVersion As String
'用途
Dim instance As VersionUpgradeEvent
Dim value As String

value = instance.SolutionVersion
[DispIdAttribute(2)] 
string SolutionVersion { get; }

備註

此屬性僅能在 OnVersionUpgrade 事件期間使用。

範例

在下列範例中,VersionUpgradeEventObject 物件的 SolutionVersion 屬性是用於在訊息方塊中顯示 InfoPath 表單範本的版本號碼:

public void OnVersionUpgrade(VersionUpgradeEvent e)
{
 thisXDocument.UI.Alert("The form version: " + e.DocumentVersion + 
  "\nThe form template version: " + e.SolutionVersion);
 e.ReturnStatus = true;   
}

請參閱

參考

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