According to this and this it should be possible to create custom classes and store them in My.Settings.

I tried doing what those articles recommended, but I can't get the most basic custom class to work:

VB Code:
  1. Imports System.ComponentModel
  2. Imports System.Configuration
  3.  
  4. <Serializable()> _
  5. Public Class CustomSetting
  6.     Inherits ApplicationSettingsBase
  7.  
  8.     Public Sub New()
  9.  
  10.     End Sub
  11.  
  12.     Public Sub New(ByVal mysetting As String)
  13.         _MySetting = mysetting
  14.     End Sub
  15.  
  16.     Private _MySetting As String
  17.     <UserScopedSetting()> _
  18.     <SettingsSerializeAs(SettingsSerializeAs.Xml)> _
  19.     Public Property MySetting As String
  20.         Get
  21.             Return _MySetting
  22.         End Get
  23.         Set(value As String)
  24.             _MySetting = value
  25.         End Set
  26.     End Property
  27. End Class

When I run the program, I get the following error:

Code:
{"Configuration system failed to initialize"}
I don't know what I'm doing wrong.