Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
1160
How we can add selected Items in XAMCombo Editor?
posted

Hi, We are using XAMCombo Editor and We have Three ComboBox First one for Country, Second for State, Third for City. when we select Country, State combo should be filled as per Country and First Index of State should be selected  same as should be in State and City Combo. We have added functionality for as we select Country, State Combo will filled as per country and as we select Sate, City Combo will be filled as per State. Now we are going to struggling to show first selected Item in Sate and City. Please let us aware how we can show first Index as selected Item in Sate and City. We have used MVVM Pattern.

 <ig:XamComboEditor x:Name="cmbCountry" EmptyText="Select ..."
                 ItemsSource="{Binding Path=DataCountry}" DisplayMemberPath="Country" SelectedValuePath="Country_Code"
                 Grid.Row="1"  Grid.Column="2" SelectedItem="{Binding SelectedCountry, Mode=TwoWay, UpdateSourceTrigger=PropertyChanged}" Width="200" Height="40" />

<ig:XamComboEditor x:Name="cmbState" Width="200" EmptyText="Select ..."
                 ItemsSource="{Binding Path=DataStates}" DisplayMemberPath="State" SelectedValuePath="State_Code"
                 Grid.Row="2"  SelectedItem="{Binding SelectedState, Mode=TwoWay, UpdateSourceTrigger=PropertyChanged}" Grid.Column="1" Height="40"  />

we have passed  SelectedState.State_Code value after binding state data, but it is showing state data not selected Item.

Please let us aware.

Thanks

Please let us aware.