Hi all,

I'm working through a textbook example on WPF and have encountered an exception that I don't understand. I won't include the XAML file of the application since I don't think that's the cause, but I can post it here if you want.

The "code-behind" file has the name "Window1.xaml.cs" and is as follows:

Code:
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Data;
using System.Windows.Documents;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Imaging;
using System.Windows.Navigation;
using System.Windows.Shapes;

namespace Presidential_Browser
{

    /// <summary>
    /// Interaction logic for Window1.xaml
    /// </summary>
    public partial class Window1 : Window
    {

        public Window1()
        {
            InitializeComponent();
        }

        private void PresPhotoListBox_SelectionChanged(object sender, SelectionChangedEventArgs e)
        {

            ListBox lb = sender as ListBox;

            if (lb != null)
            {

                if (lb.SelectedItem != null)
                {
                    string chosenName = (lb.SelectedItem as ImageURL).Name.ToString();
                    Title = chosenName;
                }
                else
                    throw new ArgumentException(
                        "Expected ListBox to call selection changed in PresPhotoListBox_SelectionChanged");

            }

        }

    }
    
}
Within the application is also the additional class file "ImageURL.cs":

Code:
using System;
using System.Collections.Generic;
using System.Windows.Media.Imaging;

namespace Presidential_Browser
{

    public class ImageURL
    {

        public string Path
        {
            get;
            private set;
        }

        public Uri ImageURI
        {
            get;
            set;
        }

        public BitmapFrame Image
        {
            get;
            private set;
        }

        public string Name
        {
            get;
            set;
        }

        public ImageURL() {}

        public ImageURL(string path, string name)
        {
            Path = path;
            ImageURI = new Uri(Path);
            Image = BitmapFrame.Create(ImageURI);
            Name = name;
        }

        public override string ToString()
        {
            return Path;
        }

    }

    public class Images : List<ImageURL> {}
    
}
When I run the application in Visual C# 2008 Express I get an "XamlParseException has occurred" dialog. This has the message " 'DependencyObject' type does not have a public TypeConverter class. Error at Line 52 Position 37."

The exception arises from the InitialiseComponent() method call in the Window1 constructor of the Window1.xaml.cs file. This then points in the call stack to the following line in the ImageURL.cs class:

Code:
public class Images : List<ImageURL> {}
Any ideas what is causing this?

Thanks