Visio) (Window.Application 屬性

會傳回與物件關聯的 Microsoft Visio 實例。 唯讀。

語法

運算式應用

表達 代表 Window 物件的變數。

傳回值

Application

範例

下列 Microsoft Visual Basic for Applications (VBA) 巨集會取得與使用中文件有關聯的 Application 物件,並在 [即時運算] 視窗中列印該物件的處理程序識別碼編號。

 
Public Sub Application_Example() 
 
 Dim vsoApplication As Visio.Application 
 Dim vsoDocument As Visio.Document 
 
 Set vsoDocument = ActiveDocument 
 
 'Get the instance of Visio associated with the Document object. 
 Set vsoApplication = vsoDocument.Application 
 Debug.Print "The process ID of the Application object associated with the active document is: " & vsoApplication.ProcessID 
 
End Sub

支援和意見反應

有關於 Office VBA 或這份文件的問題或意見反應嗎? 如需取得支援服務並提供意見反應的相關指導,請參閱 Office VBA 支援與意見反應