```
public class RegisterViewModel
{
    //Plain POCO Properties
    public RegisterModel RegisterModel { get; set; }

    //Meant to be used in SelectLists.
    public IEnumerable<CityModel> Cities { get; set; }
    public IEnumerable<CountryModel> Countries { get; set; }
}

```

Here are those classes:

```
public class RegisterModel
{
    [Required]
    [Display(Name = "Usuario")]
    public string UserName { get; set; }

    [Required]
    [DataType(DataType.EmailAddress)]
    [Display(Name = "Correo")]
    public string Email { get; set; }

    [Required]
    [StringLength(100, ErrorMessage = "Su {0} debe tener al menos {2} caracteres.", MinimumLength = 6)]
    [DataType(DataType.Password)]
    [Display(Name = "Contraseña")]
    public string Password { get; set; }

    [DataType(DataType.Password)]
    [Display(Name = "Confirme Su Contraseña")]
    [Compare("Password", ErrorMessage = "Sus contraseñas no son las mismas.")]
    public string ConfirmPassword { get; set; }

    [Required]
    [Display(Name = "Nombre")]
    public string Nombre { get; set; }

    [Required]
    [Display(Name = "Apellido")]
    public string Apellido { get; set; }

    [Required]
    [Display(Name = "Direccion")]
    public string Address { get; set; }

    [Required]
    [Display(Name = "Telefono Fijo")]
    public string Telephone { get; set; }

    [Required]
    [Display(Name = "Celular")]
    public string MobilePhone { get; set; }

    [Required]
    [Display(Name = "Fecha de Nacimiento")]
    public DateTime DateOfBirth { get; set; }

    [Required]
    [Display(Name = "Soy:")]
    public bool Sex { get; set; }

    [Required]
    [Display(Name = "Carnet")]
    public int Carnet { get; set; }
}

public class CityModel
{
    [HiddenInput(DisplayValue = false)]
    public int CityId { get; set; }

    [Required]
    [Display(Name = "Ciudad")]
    public string Name { get; set; }      
}

public class CountryModel
{
    [HiddenInput(DisplayValue = false)]
    public int CountryId { get; set; }

    [Required]
    [Display(Name = "Pais")]
    public string Name { get; set; } 
}

```

And here's how I call the RegisterViewModel in my view:

```
@model Foodiggly.WebUI.Models.RegisterViewModel

@using (Html.BeginForm()) {
    @Html.ValidationSummary(true)
    <fieldset>
        <legend>RegisterViewModel</legend>

        @Html.EditorForModel()

        <p>
            <input type="submit" value="Create" />
        </p>
    </fieldset> 
}

```

Is this error caused because my ViewModel doens't have any annotations itself? Where can I formally read about this? All I've managed to find online is the occassional blog or two but they online mention simple models, not ones that have a relationship with other objects such as this. A typical foreign key country to person relationship.

Any ideas?