Question : Dataform Combo

Hi All. I have a dataform in a silverlight 4 application and I am adding in a dataform.editTemplate so I can manipulate the names I want.
1:
2:
3:
4:
5:
6:
7:
8:
9:
10:
11:
12:
13:
<dataForm:DataForm.EditTemplate>
	<DataTemplate>
		<StackPanel VerticalAlignment="Top" Width="auto">
			<StackPanel Height="50" Margin="3,0" Orientation="Horizontal">
		<dataForm:DataField Label="Call Type" LabelPosition="Top" Width="220" >
		<ComboBox Name="cboCallStatus" GotFocus="cboCallStatus_GotFocus" Width="200" />
		/dataForm:DataField>
			/StackPanel>
		</StackPanel>
	</DataTemplate>
</dataForm:DataForm.EditTemplate>
         


I'm trying to use the Combo to show a list of values (Which it already does) AND show the value from the database (SQL Server, Entity Framework).
So just a simple list of values with the actual value bound to the combo and is changable.
I can't seem to work out what properties I need to use in XAML.
By the way I am using a DomainDataSource.
Normally with a TextBlock I would just assign Text="{Binding FieldName}"
Thanks Scott

Answer : Dataform Combo

Typically, a combobox has one item. But you can set it to have a datatemplate.
something like
<ComboBox Height="23" HorizontalAlignment="Left" Name="comboBox1" VerticalAlignment="Top" Width="120" >
  <DataTemplate>
      <StackPanel Orientation="Horizontal">
         <TextBlock Name="test1" Text="{Binding something}"></TextBlock>
         <TextBlock Name="test2" Text="{Binding somethingElse}"></TextBlock>
      </StackPanel>
   </DataTemplate>
 </ComboBox>
Random Solutions  
 
programming4us programming4us