This is a migrated thread and some comments may be shown as answers.

DataBinding Problem in RibbonView Backstage with WPF MVVM

3 Answers 164 Views
RibbonView and RibbonWindow
This is a migrated thread and some comments may be shown as answers.
Srinivasareddy
Top achievements
Rank 1
Srinivasareddy asked on 13 Sep 2012, 06:27 AM
Hi Team,

I am working with WPF MVVM using RadRibbonView.
DataBinding not Working inside Ribbonview Backstage.

<telerik:RadRibbonView >
 <telerik:RadRibbonView.Backstage >
                <telerik:RadRibbonBackstage>
 <telerik:RadRibbonBackstageItem Header="Rooms Layout">
                        <Grid Background="Gainsboro">
                            <Grid.RowDefinitions >
                                <RowDefinition Height="100"></RowDefinition>
                                <RowDefinition Height="100"></RowDefinition>
                            </Grid.RowDefinitions>
                            <TextBox Text="Sample" Foreground="Green" Width="100" Grid.Row="0" Name="txtSample">  </TextBox>
                            <TextBlock Background="Green" Foreground="Yellow" Text="{Binding ElementName=txtSample,Path=Sample}" Width="100" Grid.Row="1"></TextBlock>
                        </Grid>
                    </telerik:RadRibbonBackstageItem>
 </telerik:RadRibbonView.Backstage >
                </telerik:RadRibbonBackstage>
</telerik:RadRibbonView >

Please help me.
Thanks,
Srinivas.

3 Answers, 1 is accepted

Sort by
0
Tina Stancheva
Telerik team
answered on 14 Sep 2012, 09:37 AM
Hello Srinivas,

Are you refereeing to this line of code:
<TextBlock Background="Green" Foreground="Yellow" Text="{Binding ElementName=txtSample,Path=Sample}" Width="100" Grid.Row="1"></TextBlock>
because I noticed that you're trying to bind this TextBlock Text property to a Sample property of a TextBox. I think you meant to bind it to the Text property instead:
<TextBlock Background="Green" Foreground="Yellow"
                    Text="{Binding ElementName=txtSample,Path=Text}"
                    Width="100" Grid.Row="1"></TextBlock>
 Please change that and let me know if this was the issue or I'm missing something.

Kind regards,
Tina Stancheva
the Telerik team

Time to cast your vote for Telerik! Tell DevPro Connections and Windows IT Pro why Telerik is your choice. Telerik is nominated in a total of 25 categories.

0
shankar parshimoni
Top achievements
Rank 1
answered on 27 Sep 2012, 11:02 AM
Hello Hi ,
I have one combobox ,one button and one gridview in wpf page .my task is ,when ever we select value in the combobox and click on the button ,selected value related information should be displayed in te GridView from the database..task is being devloped in mvvm pattern please tell me how can i show values in GridView.
0
Tina Stancheva
Telerik team
answered on 02 Oct 2012, 09:12 AM
Hello Shukreya,

From your description I gather you need to create a master-detail scenario. If this is indeed the case, you can bind the RadComboBox ItemsSource to a collection of data and use the selected item in the ComboBox control to populate the RadGridView.ItemsSource collection.

You can take a look at this blog post describing how to implement a master-detail scenario using two RadGridView controls and you can also take a look at the FirstLook demo of the RadComboBox demonstrating a sample master-detail scenario as well.

If you encounter any issues with the RadControls while building your solution, you can post them through our support ticketing system specifying the control the issues are related to. This way we'll be able to manage your queries more precisely and forward them to the respective developers if needed.

Kind regards,
Tina Stancheva
the Telerik team

Explore the entire Telerik portfolio by downloading Telerik DevCraft Ultimate.

Tags
RibbonView and RibbonWindow
Asked by
Srinivasareddy
Top achievements
Rank 1
Answers by
Tina Stancheva
Telerik team
shankar parshimoni
Top achievements
Rank 1
Share this question
or