IVsUserSettings Interface

Interface implemented by VSPackages needing their state information persisted by the Visual Studio settings mechanism.

Namespace:  Microsoft.VisualStudio.Shell.Interop
Assembly:  Microsoft.VisualStudio.Shell.Interop.8.0 (in Microsoft.VisualStudio.Shell.Interop.8.0.dll)

Syntax

'Declaration
<GuidAttribute("770E285D-3B7D-4342-B3C4-42BD9F53A300")> _
<InterfaceTypeAttribute()> _
Public Interface IVsUserSettings
[GuidAttribute("770E285D-3B7D-4342-B3C4-42BD9F53A300")]
[InterfaceTypeAttribute()]
public interface IVsUserSettings
[GuidAttribute(L"770E285D-3B7D-4342-B3C4-42BD9F53A300")]
[InterfaceTypeAttribute()]
public interface class IVsUserSettings
[<GuidAttribute("770E285D-3B7D-4342-B3C4-42BD9F53A300")>]
[<InterfaceTypeAttribute()>]
type IVsUserSettings =  interface end
public interface IVsUserSettings

The IVsUserSettings type exposes the following members.

Methods

  Name Description
Public method ExportSettings Saves a VSPackage's configuration using the Visual Studio settings mechanism when the export option of the Import/Export Settings feature available on the IDE’s Tools menu is selected by a user.
Public method ImportSettings Retrieves a VSPackage's configuration using the Visual Studio settings mechanism when a user selects the import option of the Import/Export Settings feature on the IDE’s Tools menu.

Top

Remarks

To persist a VSPackage configuration using the IVsPackage interface requires:

  • Registration of the VSPackage as providing Visual Studio settings support, this is referred to as defining a Custom Settings Point. For more information see, Persisting Settings

  • The implementation of two of the IVsPackage interface's methods: ExportSettings and ImportSettings.

  • The optional implementation of the IVsUserSettingsQuery interface if management of when settings are saved is required.

For more information, see How to: Export Settings By Using Interop Assemblies and How to: Use Interop Assemblies to Import Settings.

Notes to Implementers

Implement on interop assembly based VSPackages derived from IVsPackage to participate in the Visual Studio settings mechanism when users select the Import/Export Settings feature available on the IDE’s Tools menu.

See Also

Reference

Microsoft.VisualStudio.Shell.Interop Namespace

ExportSettings

ImportSettings

IVsUserSettingsQuery

Other Resources

Persisting Settings

How to: Export Settings By Using Interop Assemblies

How to: Use Interop Assemblies to Import Settings