I am using XamDataDataGrid(NetAdvantage for WPF 2008 Vol. 1 Express Hotfix).
My XamDataGrid has cells it has combobox. combobox has items it is generated by object provider.
but, Sometimes, My XamDataGrid can not display items of combobox.
My Code is follows.
<igDP:XamDataGrid.Resources> <ObjectDataProvider x:Key="odpPartitionList" ObjectType="{x:Type dev718plus:Programmer}" MethodName="GetPartitionList"/> <ObjectDataProvider x:Key="odpZoneList" ObjectType="{x:Type dev718plus:Programmer}" MethodName="GetZoneList"/> <ObjectDataProvider x:Key="odpPanelList" ObjectType="{x:Type dev718plus:Programmer}" MethodName="GetPanelList"/> <ObjectDataProvider x:Key="odpConsoleList" ObjectType="{x:Type dev718plus:Programmer}" MethodName="GetConsoleList"/> <ObjectDataProvider x:Key="odpIOPortList" ObjectType="{x:Type dev718plus:Programmer}" MethodName="GetIOPortList"/> <ObjectDataProvider x:Key="odpDoorList" ObjectType="{x:Type dev718plus:Programmer}" MethodName="GetDoorList"/>
</igDP:XamDataGrid.Resources>
.................................................................
<Style x:Key="WhenInfoCellValueEditorStyle" TargetType="{x:Type igDP:CellValuePresenter}"> <Style.Triggers> <DataTrigger Binding="{Binding Path=Cells[Action].Value}" Value="6"> <Setter Property="Template"> <Setter.Value> <ControlTemplate TargetType="{x:Type igDP:CellValuePresenter}"> <Grid> <ComboBox Grid.Column="0" ItemsSource="{Binding Source={StaticResource odpPanelList}}" BorderThickness="0" IsSynchronizedWithCurrentItem="True" DisplayMemberPath="Text" SelectedValuePath="Value" SelectedValue="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=Value.[0], Mode=TwoWay, UpdateSourceTrigger=PropertyChanged}"/> </Grid> </ControlTemplate> </Setter.Value> </Setter> </DataTrigger>
The odpPartitionList is normal. but, The odpPanelList is abnormal. however, somtimes, The odpPanelList is normal
Hello,
Excuse me for the late reply, we are making efforts to ensure all posts are addressed by an Infragistics expert. We believe that the other community members could benefit from this thread as well. I have looking into the issue that you described and it seems that the items are loaded correctly in the ComboBox when its ItemsSource is ObjectDataProvider. I have created a sample application using the code snippet that you have sent and it seems to work correctly. I have tested the sample with last service release for version 8.1 and also with version 11.1 and the sample seems to behave as it supposed to.
If you need any further assistance please do not hesitate to ask.
Sincerely,
Krasimir
Developer Support Engineer
Infragistics
www.infragistics.com/support