0
我正在尋找一些方法,可以讓我把devexpress ComboBoxEdit控件放在Bar中。我們可以在Bar中放置一個devexpress ComboBoxEdit控件嗎?
例如:
<dxb:BarManager x:Name="barManager" CreateStandardLayout="False" Grid.Row="1" Grid.Column="0">
<dxb:BarManager.Items>
<dxb:BarStaticItem Name="lblState" Content="State"/>
<dxb:BarLinkContainerItem Name="cmbStates" >
<dxb:BarLinkContainerItem.Content>
<dxb:ComboBoxEdit DisplayMember="Description" ValueMember="Id" EditValue="{Binding Filter.EquipmentId, Mode=TwoWay}" ItemsSource="{Binding Path=OrderStates, Mode=TwoWay}">
</dxb:ComboBoxEdit>
</dxb:BarLinkContainerItem.Content>
</dxb:BarLinkContainerItem>
</dxb:BarManager.Items>
<dxb:BarManager.Bars>
<dxb:Bar x:Name="Bar" Caption="Bar" UseWholeRow="True">
<dxb:Bar.DockInfo>
<dxb:BarDockInfo ContainerName="Top"/>
</dxb:Bar.DockInfo>
<dxb:Bar.ItemLinks>
<dxb:BarStaticItemLink BarItemName="lblState" />
<dxb:BarLinkContainerItemLink BarItemName="cmbStates" />
</dxb:Bar.ItemLinks>
</dxb:Bar>
</dxb:BarManager.Bars>
</dxb:BarManager>
否則會導致以下錯誤:
UIElement can't be set as content for a BarItemLink.
是否有可能實現這一目標?有什麼選擇可以做到這一點?
感謝您的及時回覆。它真的幫助:) – Baig