You should consider writing a class that stores some kind of arbitrary detail for a car:
class CarDetail
{
public string DetailName { get; set; }
public string DetailValue { get; set; }
}
Then create a CarDetail object for each detail you want to collect. If you store this collection in a ViewModel, you can then bind an items control to it - and have the items control show a textbox :)
<itemscontrol itemssource="{Binding Details}">
<itemscontrol.itemtemplate>
<datatemplate>
<stackpanel orientation="Horizontal">
<textblock text="{Binding DetailName}" />
<textbox text="{Binding DetailValue}" />
</stackpanel>
</datatemplate>
</itemscontrol.itemtemplate>
</itemscontrol>
So what you are doing here is saying that we have a set of some arbitrary details - and how do we present each one? As a label the name of the detail, alongside a textbox to get the detail.
You can then later extend it so that if you want to collect other types of details you can use other datatemplates - one for a combo box, one for a checkbox etc.
To do this in this way you'll need to make sure that that classes implement INotifyPropertyChanged, read up on this at:
http://www.codeproject.com/KB/WPF/wpfstepbystep1.aspx[
^]
which explains how to do that, or use a MVVM library such as
Cinch V2: Version 2 of my Cinch MVVM framework: Part 1 of n[
^] or even my own very simple one
Introducing Apex[
^]
Good luck!