Question: This is probably simple but I'm trying to get the directory root in my code.

Here is my code:

```
var appdir = AppDomain.CurrentDomain.BaseDirectory;
var ppsdir = Directory.GetParent(appdir).FullName;

appdir  is coming back as "C:\\Program Files (x86)\\PPS\\PpsUpdate\\"
but ppsdir is coming back as "C:\\Program Files (x86)\\PPS\\PpsUpdate"

```

I need the ppsdir to be "C:\Program Files (x86)\PPS" so I'm not sure what I am doing wrong.

Answer: 
Use a `BooleanField` instead of an `IntegerField`. This doesn't require changing the database tables because `BooleanField` internally translates booleans to 1s and 0s. MySQL's "boolean" column type is nothing more than an alias for tinyint(1) anyway, i.e. an integer type used as a 1/0 truth value. You can do this with other integer column types, too.
You can add a `clean_active` method to your form to normalize the input:

```
class CreateUserForm(ModelForm):
    ...

    def clean_active(self):
        return 1 if self.cleaned_data['active'] else 0

```

See also: [cleaning and validating form input in Django](https://docs.djangoproject.com/en/1.6/ref/forms/validation/).

However, you should also ask yourself do you *really* need to represent your data in MySql in that way. It would be *way* more convenient to just use `BooleanField` instead of `IntegerField` for that field.