Skip to content

Commit b4ea19e

Browse files
Update 1- 1887260 (#9417)
* Update 1- 1887260 * Update 1- 1887260 * update1 - 1887260 * Final update * Update in link * update after review
1 parent 553e4a0 commit b4ea19e

File tree

1 file changed

+18
-16
lines changed

1 file changed

+18
-16
lines changed

docs/vsto/registry-entries-for-vsto-add-ins.md

Lines changed: 18 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
---
22
title: "Registry entries for VSTO Add-ins"
33
description: Learn how you can create a specific set of registry entries when you deploy VSTO Add-ins that are created by using Visual Studio.
4-
ms.custom: SEO-VS-2020
5-
ms.date: "08/14/2019"
4+
ms.custom: SEO-VS-2020, devdivchpfy22
5+
ms.date: "01/27/2022"
66
ms.topic: "conceptual"
77
dev_langs:
88
- "VB"
@@ -27,7 +27,9 @@ ms.workload:
2727

2828
[!include[Add-ins note](includes/addinsnote.md)]
2929

30-
When you build your project, Visual Studio creates these registry entries on the development computer so that you can easily run and debug the VSTO Add-in. If you use ClickOnce to deploy your VSTO Add-in, the registry entries are automatically created on the end-user computer. If you use Windows Installer to deploy your VSTO Add-in, you must configure the InstallShield Limited Edition project to create the registry entries on the end-user computer.
30+
When you build your project, Visual Studio creates these registry entries on the development computer. This helps you easily run and debug the VSTO Add-in. Using ClickOnce to deploy your VSTO Add-in, the registry entries are automatically created on the end-user computer.
31+
32+
For more information about how to deploy a VSTO Solution Using Windows Installer, see [Deploying a VSTO Solution Using Windows Installer](../vsto/deploying-a-vsto-solution-by-using-windows-installer.md).
3133

3234
For more information about how the registry entries are used during the load process for VSTO Add-ins, see [Architecture of VSTO Add-ins](../vsto/architecture-of-vsto-add-ins.md).
3335

@@ -37,9 +39,9 @@ ms.workload:
3739
## Register VSTO Add-ins for the current user vs. all users
3840
When a VSTO Add-in is installed, it can be registered in two ways:
3941

40-
- For the current user only (that is, it is available only to the user that is logged on to the computer when the VSTO Add-in is installed). In this case, the registry entries are created under the **HKEY_CURRENT_USER**.
42+
- For the current user only (The VSTO Add-in is available only to the user that was logged onto the computer when the Add-in was installed). In this case, the registry entries are created under the **HKEY_CURRENT_USER**.
4143

42-
- For all users (that is, any user that logs on to the computer can use the VSTO Add-in). In this case, the registry entries are created under **HKEY_LOCAL_MACHINE**.
44+
- For all users (that is, any user that signs in to the computer can use the VSTO Add-in). In this case, the registry entries are created under **HKEY_LOCAL_MACHINE**.
4345

4446
All VSTO Add-ins that you create by using Visual Studio can be registered for the current user. However, VSTO Add-ins can be registered for all users only in certain scenarios. These scenarios depend on the version of Microsoft Office on the computer and how the VSTO Add-in was deployed.
4547

@@ -57,25 +59,25 @@ ms.workload:
5759
> [!NOTE]
5860
> If the installer is targeting all users on 64-bit Windows, it is recommended that it includes two registry entries, one under the HKEY_LOCAL_MACHINE\Software\Microsoft and one under the HKEY_LOCAL_MACHINE\Software\\**WOW6432Node**\Microsoft hive. This is because it's possible for users to use either 32-bit or 64-bit versions of Office on the computer.
5961
>
60-
>If the Installer is targeting the current user, it does not need to install to the WOW6432Node because the HKEY_CURRENT_USER\Software path is shared.
62+
>If the Installer is targeting the current user, it doesn't need to install to the WOW6432Node because the HKEY_CURRENT_USER\Software path is shared.
6163
>
62-
>For more information please see [32-bit and 64-bit Application Data in the Registry](/windows/win32/sysinfo/32-bit-and-64-bit-application-data-in-the-registry)
64+
>For more information, see [32-bit and 64-bit Application Data in the Registry](/windows/win32/sysinfo/32-bit-and-64-bit-application-data-in-the-registry).
6365
6466
The following table lists the entries under this registry key.
6567

6668
|Entry|Type|Value|
6769
|-----------|----------|-----------|
6870
|**Description**|REG_SZ|Required. A brief description of the VSTO Add-in.<br /><br /> This description is displayed when the user selects the VSTO Add-in in the **Add-Ins** pane of the **Options** dialog box in the Microsoft Office application.|
6971
|**FriendlyName**|REG_SZ|Required. A descriptive name of the VSTO Add-in that is displayed in the **COM Add-Ins** dialog box in the Microsoft Office application. The default value is the VSTO Add-in ID.|
70-
|**LoadBehavior**|REG_DWORD|Required. A value that specifies when the application attempts to load the VSTO Add-in and the current state of the VSTO Add-in (loaded or unloaded).<br /><br /> By default, this entry is set to 3, which specifies that the VSTO Add-in is loaded at startup. For more information, see [LoadBehavior values](#LoadBehavior). **Note:** If a user disables the VSTO Add-in, that action modifies **LoadBehavior** value in the **HKEY_CURRENT_USER** registry hive. For each user, the value of the **LoadBehavior** value in the HKEY_CURRENT_USER hive overrides the default **LoadBehavior** defined in the **HKEY_LOCAL_MACHINE** hive.|
71-
|**Manifest**|REG_SZ|Required. The full path of the deployment manifest for the VSTO Add-in. The path can be a location on the local computer, a network share (UNC), or a Web server (HTTP).<br /><br /> If you use Windows Installer to deploy the solution, you must add the prefix **file:///** to the **manifest** path. You must also append the string **&#124;vstolocal** (that is, the pipe character **&#124;** followed by **vstolocal**) to the end of this path. This ensures that your solution is loaded from the installation folder, rather than the ClickOnce cache. For more information, see [Deploy an Office solution by using Windows Installer](../vsto/deploying-a-vsto-solution-by-using-windows-installer.md). **Note:** When you build a VSTO Add-in on the development computer, Visual Studio automatically appends the **&#124;vstolocal** string to this registry entry.|
72+
|**LoadBehavior**|REG_DWORD|Required. A value that specifies when the application attempts to load the VSTO Add-in and the current state of the VSTO Add-in (loaded or unloaded).<br /><br /> By default, this entry is set to 3, which specifies that the VSTO Add-in is loaded at startup. For more information, see [LoadBehavior values](#LoadBehavior).<br /><br />**Note:** If a user disables the VSTO Add-in, that action modifies **LoadBehavior** value in the **HKEY_CURRENT_USER** registry hive. For each user, the value of the **LoadBehavior** value in the HKEY_CURRENT_USER hive overrides the default **LoadBehavior** defined in the **HKEY_LOCAL_MACHINE** hive.|
73+
|**Manifest**|REG_SZ|Required. The full path of the deployment manifest for the VSTO Add-in. The path can be a location on the local computer, a network share (UNC), or a Web server (HTTP).<br /><br /> If you use Windows Installer to deploy the solution, you must add the prefix **file:///** to the **manifest** path. You must also append the string **&#124;vstolocal** (that is, the pipe character **&#124;** followed by **vstolocal**) to the end of this path. This ensures that your solution is loaded from the installation folder, rather than the ClickOnce cache. For more information, see [Deploy an Office solution by using Windows Installer](../vsto/deploying-a-vsto-solution-by-using-windows-installer.md).<br /><br />**Note:** When you build a VSTO Add-in on the development computer, Visual Studio automatically appends the **&#124;vstolocal** string to this registry entry.|
7274

7375
### <a name="OutlookEntries"></a> Registry entries for Outlook form regions
7476
If you create a custom form region in a VSTO Add-in for Outlook, additional registry entries are used to register the form region with Outlook. These entries are created under a different registry key for each message class that the form region supports. These registry keys are in the following location, where *Root* is **HKEY_CURRENT_USER** or **HKEY_LOCAL_MACHINE**.
7577

7678
*Root*\Software\Microsoft\Office\Outlook\FormRegions\\*message class*
7779

78-
Like the other registry entries shared by all VSTO Add-ins, Visual Studio creates the form region registry entries on the development computer when you build your project. If you use ClickOnce to deploy your VSTO Add-in, the registry entries are automatically created on the end-user computer. If you use Windows Installer to deploy your VSTO Add-in, you must configure the InstallShield Limited Edition project to create the registry entries on the end-user computer.
80+
Like the other registry entries shared by all VSTO Add-ins, Visual Studio creates the form region registry entries on the development computer when you build your project. Using ClickOnce to deploy your VSTO Add-in, the registry entries are automatically created on the end-user computer. When you use Windows Installer to deploy your VSTO Add-in, you must configure the InstallShield Limited Edition project to create the registry entries on the end-user computer.
7981

8082
For more information about the form region registry entries, see [Specify the location of a form region in a custom form](/office/vba/outlook/Concepts/Creating-Form-Regions/specify-the-location-of-a-form-region-in-a-custom-form). For more information about Outlook form regions, see [Create Outlook form regions](../vsto/creating-outlook-form-regions.md).
8183

@@ -88,13 +90,13 @@ ms.workload:
8890

8991
|Value (in decimal)|VSTO Add-in status|VSTO Add-in load behavior|Description|
9092
|--------------------------|-------------------------|--------------------------------|-----------------|
91-
|0|Unloaded|Do not load automatically|The application never tries to load the VSTO Add-in automatically. The user can try to manually load the VSTO Add-in, or the VSTO Add-in can be loaded programmatically.<br /><br /> If the VSTO Add-in is successfully loaded, the **LoadBehavior** value remains 0, but the status of the VSTO Add-in in the **COM Add-ins** dialog box is updated to indicate that the VSTO Add-in is loaded.|
92-
|1|Loaded|Do not load automatically|The application never tries to load the VSTO Add-in automatically. The user can try to manually load the VSTO Add-in, or the VSTO Add-in can be loaded programmatically.<br /><br /> Although the **COM Add-ins** dialog box indicates that the VSTO Add-in is loaded after the application starts, the VSTO Add-in isn't loaded until it is loaded manually or programmatically.<br /><br /> If the application successfully loads the VSTO Add-in, the **LoadBehavior** value changes to 0, and remains at 0 after the application closes.|
93-
|2|Unloaded|Load at startup|The application does not try to load the VSTO Add-in automatically. The user can try to manually load the VSTO Add-in, or the VSTO Add-in can be loaded programmatically.<br /><br /> If the application successfully loads the VSTO Add-in, the **LoadBehavior** value changes to 3, and remains at 3 after the application closes.|
93+
|0|Unloaded|Don't load automatically|The application never tries to load the VSTO Add-in automatically. The user can try to manually load the VSTO Add-in, or the VSTO Add-in can be loaded programmatically.<br /><br /> If the VSTO Add-in is successfully loaded, the **LoadBehavior** value remains 0, but the status of the VSTO Add-in in the **COM Add-ins** dialog box is updated to indicate that the VSTO Add-in is loaded.|
94+
|1|Loaded|Don't load automatically|The application never tries to load the VSTO Add-in automatically. The user can try to manually load the VSTO Add-in, or the VSTO Add-in can be loaded programmatically.<br /><br /> Although the **COM Add-ins** dialog box indicates that the VSTO Add-in is loaded after the application starts, the VSTO Add-in isn't loaded until it's loaded manually or programmatically.<br /><br /> If the application successfully loads the VSTO Add-in, the **LoadBehavior** value changes to 0, and remains at 0 after the application closes.|
95+
|2|Unloaded|Load at startup|The application doesn't try to load the VSTO Add-in automatically. The user can try to manually load the VSTO Add-in, or the VSTO Add-in can be loaded programmatically.<br /><br /> If the application successfully loads the VSTO Add-in, the **LoadBehavior** value changes to 3, and remains at 3 after the application closes.|
9496
|3|Loaded|Load at startup|The application tries to load the VSTO Add-in when the application starts. This is the default value when you build or publish a VSTO Add-in in Visual Studio.<br /><br /> If the application successfully loads the VSTO Add-in, the **LoadBehavior** value remains 3. If an error occurs when loading the VSTO Add-in, the **LoadBehavior** value changes to 2, and remains at 2 after the application closes.|
95-
|8|Unloaded|Load on demand|The application does not try to load the VSTO Add-in automatically. The user can try to manually load the VSTO Add-in, or the VSTO Add-in can be loaded programmatically.<br /><br /> If the application successfully loads the VSTO Add-in, the **LoadBehavior** value changes to 9.|
96-
|9|Loaded|Load on demand|The VSTO Add-in will be loaded only when the application requires it, such as when a user clicks a UI element that uses functionality in the VSTO Add-in (for example, a custom button in the Ribbon).<br /><br /> If the application successfully loads the VSTO Add-in, the **LoadBehavior** value remains 9, but the status of the VSTO Add-in in the **COM Add-ins** dialog box is updated to indicate that the VSTO Add-in is currently loaded. If an error occurs when loading the VSTO Add-in, the **LoadBehavior** value changes to 8.|
97-
|16|Loaded|Load first time, then load on demand|Set this value if you want your VSTO Add-in to be loaded on demand. The application loads the VSTO Add-in when the user runs the application for the first time. The next time the user runs the application, the application loads any UI elements that are defined by the VSTO Add-in, but the VSTO Add-in is not loaded until the user clicks a UI element that is associated with the VSTO Add-in.<br /><br /> When the application successfully loads the VSTO Add-in for the first time, the **LoadBehavior** value remains 16 while the VSTO Add-in is loaded. After the application closes, the **LoadBehavior** value changes to 9.|
97+
|8|Unloaded|Load on demand|The application doesn't try to load the VSTO Add-in automatically. The user can try to manually load the VSTO Add-in, or the VSTO Add-in can be loaded programmatically.<br /><br /> If the application successfully loads the VSTO Add-in, the **LoadBehavior** value changes to 9.|
98+
|9|Loaded|Load on demand|The VSTO Add-in will be loaded only when the application requires it. Such as when a user selects a UI element that uses functionality in the VSTO Add-in (for example, a custom button in the Ribbon).<br /><br /> If the application successfully loads the VSTO Add-in, the **LoadBehavior** value remains 9, but the status of the VSTO Add-in in the **COM Add-ins** dialog box is updated to indicate that the VSTO Add-in is currently loaded. If an error occurs when loading the VSTO Add-in, the **LoadBehavior** value changes to 8.|
99+
|16|Loaded|Load first time, then load on demand|Set this value if you want your VSTO Add-in to be loaded on demand. The application loads the VSTO Add-in when the user runs the application for the first time. The next time the user runs the application, the application loads any UI elements that are defined by the VSTO Add-in. However, the VSTO Add-in isn't loaded until the user selects a UI element that is associated with the VSTO Add-in.<br /><br /> When the application successfully loads the VSTO Add-in for the first time, the **LoadBehavior** value remains 16 while the VSTO Add-in is loaded. After the application closes, the **LoadBehavior** value changes to 9.|
98100

99101
## See also
100102
- [Architecture of Office solutions in Visual Studio](../vsto/architecture-of-office-solutions-in-visual-studio.md)

0 commit comments

Comments
 (0)