Question: Model:

```
class Subject(models.Model):
  name = models.CharField(max_length=100)
  slug = models.SlugField(unique=True)
  description = models.TextField(blank=True,null=True)

```

Forms:

```
class SearchTypeForm(forms.Form):
  subject = forms.ModelChoiceField(queryset = Subject.objects.all())

```

Views:

```
...
context['search_type_form'] = SearchTypeForm()
...

```

Template:

```
{{search_type_form.subject}}

```

In actual templates the search type form is rendered as:

```
<select id="id_subject" name="subject">
<option selected="selected" value="">---------</option>
<option value="1">subject 1</option>
<option value="2">subject 2</option>
...
</select>

```

In the value field(of above dropdown list) is the id of the corresponding subject, How it be changed to some other field, like is we want to make it the **slug field of Subject model**.

Answer: 
Instead of null in your dependency property metadata insert 

```
new UIPropertyMetadata("YOUR DEFAULT VALUE GOES HERE")

```

So now it becomes 

```
public static readonly DependencyProperty MyFruitProperty =
    DependencyProperty.Register("MyFruit", typeof(Fruit), typeof(CircularGauge), new UIPropertyMetadata("YOUR DEFAULT VALUE GOES HERE"));

```
You need to use `PropertyMetaData` like this:

```
class MyValidation
{
    public bool status
    {
        get { return (bool)GetValue(statusProperty); }
        set { SetValue(statusProperty, value); }
    }

    public static readonly DependencyProperty statusProperty = DependencyProperty.Register("status", typeof(bool), typeof(MyValidation),new PropertyMetadata(false));
}

```