Office 方案的應用程式資訊清單 (2007 系統)
更新:2007 年 11 月
注意 |
適用於 |
---|---|
本主題中的資訊僅適用於指定的 Visual Studio Tools for Office 專案和 Microsoft Office 版本。 如需詳細資訊,請參閱依應用程式和專案類型提供的功能。 |
專案類型
Microsoft Office 版本
|
Visual Studio Tools for Office 方案中的應用程式資訊清單是 XML 檔案,該檔案描述載入 Microsoft Office 方案中的組件。
Visual Studio Tools for Office 會使用 ClickOnce 應用程式資訊清單 參考中定義的 ClickOnce 應用程式資訊清單結構描述。
Visual Studio Tools for Office 應用程式資訊清單會使用下列 ClickOnce 項目與屬性。
項目 |
說明 |
屬性 |
---|---|---|
必要項。最上層項目。 |
manifestVersion |
|
必要項。識別 ClickOnce 應用程式的主要組件。 |
name version publicKeyToken processorArchitecture language |
|
識別應用程式的安全性需求。 |
無 |
|
必要項。識別執行的應用程式程式碼進入點。 |
name dependencyName customHostSpecified |
|
必要項。識別要執行應用程式所需的每個相依性。選擇性地識別需要預先安裝的組件。 |
無 |
|
必要項。識別應用程式所使用的每個非組件檔案。可以包括與檔案相關聯的元件物件模型 (Component Object Model,COM) 隔離資料。 |
name size |
Visual Studio Tools for Office 應用程式資訊清單在 co.v1 命名空間中具有下列項目。
<entryPoint>
<co.v1:customHostSpecified />
</entryPoint>
Visual Studio Tools for Office 應用程式資訊清單在 vstav2 命名空間中也具有下列項目與屬性。
<addIn>
<entryPoints>
<entryPoint>
</entryPoint>
</entryPoints>
<update></update>
<application>
<customization>
</customization>
</application
</addIn>
項目 |
說明 |
屬性 |
---|---|---|
必要項。將資訊清單特別標記為 Office 方案。 |
無 |
|
必要項。將進入點儲存至單一命名空間。 |
無 |
|
必要項。將要執行的所有組件予以群組。 |
無 |
|
必要項。識別要執行的組件。 |
class contract |
|
必要項。設定方案的更新。 |
enabled expiration |
|
必要項。將應用程式特定的資訊包裝至單一節點。 |
無 |
|
必要項。將應用程式主機特定的資訊儲存至不同的命名空間。 |
xmlns |
|
文件層級的方案才需要。儲存自訂的特定資訊。 |
solutionId |
|
應用程式層級的方案才需要。儲存自訂的特定資訊。 |
application loadBehavior keyName |
|
選擇項,儲存出現在已安裝之增益集清單中的增益集名稱。 |
無 |
|
應用程式層級的增益集才需要。儲存出現在已安裝之程式清單中的描述。 |
無 |
|
只有包含表單區域的 Outlook 2007 增益集才需要。 |
無 |
|
只有包含表單區域的 Outlook 2007 增益集才需要。 |
name |
備註
您可以手動編輯 Visual Studio Tools for Office 方案中的應用程式和部署資訊清單。編譯應用程式和部署資訊清單後,資訊清單和產生編輯工具 (mage.exe 和 mageui.exe) 必須重新簽署資訊清單。先簽署應用程式資訊清單,再簽署部署資訊清單。如需詳細資訊,請參閱資訊清單產生和編輯工具 (Mage.exe) 和圖形用戶端、資訊清單產生和編輯工具 (MageUI.exe)。
檔案位置
應用程式資訊清單是方案的單一版本所特有的。因此,應用程式資訊清單應該與部署資訊清單分開儲存。Visual Studio 會將版本特定的檔案,放在發行資料夾中與其 Application Files 子目錄相關聯之版本所命名的子目錄中。
檔名語法
應用程式資訊清單的檔名應該是 assemblyIdentity 項目中識別的應用程式完整名稱和副檔名,其後接著副檔名 .manifest。例如,參考 OutlookAddIn1.dll 自訂的應用程式資訊清單會使用下列檔案名稱語法。
OutlookAddIn1.dll.manifest
ExcelWorkbook1.dll.manifest
文件層級自訂範例
說明
下列程式碼範例會示範 Visual Studio Tools for Office 方案所專屬的應用程式資訊清單區段。這是 Microsoft Office Excel 2007 文件層級自訂。
程式碼
<entryPoint>
<co.v1:customHostSpecified />
</entryPoint>
[...]
<vstav2:addIn xmlns:vstav2="urn:schemas-microsoft-com:vsta.v2">
<vstav2:entryPoints>
<vstav2:entryPoint class="ExcelWorkbook1.ThisWorkbook">
<assemblyIdentity
name="ExcelWorkbook1"
version="1.0.0.0"
language="neutral"
processorArchitecture="msil" />
</vstav2:entryPoint>
<vstav2:entryPoint class="ExcelWorkbook1.Sheet1">
<assemblyIdentity
name="ExcelWorkbook1"
version="1.0.0.0"
language="neutral"
processorArchitecture="msil" />
</vstav2:entryPoint>
<vstav2:entryPoint class="ExcelWorkbook1.Sheet2">
<assemblyIdentity
name="ExcelWorkbook1"
version="1.0.0.0"
language="neutral"
processorArchitecture="msil" />
</vstav2:entryPoint>
<vstav2:entryPoint class="ExcelWorkbook1.Sheet3">
<assemblyIdentity
name="ExcelWorkbook1"
version="1.0.0.0"
language="neutral"
processorArchitecture="msil" />
</vstav2:entryPoint>
</vstav2:entryPoints>
<vstav2:update enabled="true">
<vstav2:expiration maximumAge="7" unit="days" />
</vstav2:update>
<vstav2:application>
<vstov3:customization
xmlns:vstov3="urn:schemas-microsoft-com:vsto.v3">
<vstov3:document
solutionId="989..." />
</vstov3:customization>
</vstav2:application>
</vstav2:addIn>
應用程式層級增益集範例
說明
下列程式碼範例會示範 Visual Studio Tools for Office 方案所專屬的應用程式資訊清單區段。這是包含表單區域的 Microsoft Office Outlook 2007 應用程式層級增益集。
程式碼
<entryPoint>
<co.v1:customHostSpecified />
</entryPoint>
[...]
<vstav2:addIn xmlns:vstav2="urn:schemas-microsoft-com:vsta.v2">
<vstav2:entryPoints>
<vstav2:entryPoint class="OutlookAddIn1.ThisAddIn">
<assemblyIdentity
name="OutlookAddIn1"
version="1.0.0.0"
language="neutral"
processorArchitecture="msil" />
</vstav2:entryPoint>
</vstav2:entryPoints>
<vstav2:update enabled="true">
<vstav2:expiration maximumAge="7" unit="days" />
</vstav2:update>
<vstav2:application>
<vstov3:customization
xmlns:vstov3="urn:schemas-microsoft-com:vsto.v3">
<vstov3:appAddIn
application="Outlook"
loadBehavior="3"
keyName="OutlookAddIn1">
<vstov3:friendlyName>
OutlookAddIn1
</vstov3:friendlyName>
<vstov3:description>
OutlookAddIn1 - Outlook add-in created with
Visual Studio Tools for Office
</vstov3:description>
<vstov3:formRegions>
<vstov3:formRegion
name="OutlookAddIn1.FormRegion1">
<vstov3:messageClass name="IPM.Note" />
<vstov3:messageClass name="IPM.Contact" />
<vstov3:messageClass name="IPM.Appointment" />
</vstov3:formRegion>
</vstov3:formRegions>
</vstov3:appAddIn>
</vstov3:customization>
</vstav2:application>
</vstav2:addIn>