Telerik Forums
UI for WPF Forum
0 answers
175 views

Hello,

I've developed a RadGridView as follow :

 <telerik:RadGridView Grid.Row="1" ItemsSource="{Binding SecuritiesNoteResult}" AutoGenerateColumns="False">
            <telerik:RadGridView.Columns>
             <!-- some other grid-->
                <telerik:GridViewDataColumn UniqueName="FileOpen" Header="Visualizza" x:name="test">
                    <telerik:GridViewDataColumn.CellTemplate>
                        <DataTemplate>
                            <Button HorizontalContentAlignment="Center" Click="Button_Click" >
                                <Button.Content>
                                    <StackPanel Orientation="Horizontal">
                                        <Image Source="/DOME;component/Media/pdfDocument.png" Height="20" Width="20" />

                                    </StackPanel>
                                </Button.Content>
                            </Button>
                        </DataTemplate>
                    </telerik:GridViewDataColumn.CellTemplate>
                </telerik:GridViewDataColumn>
            </telerik:RadGridView.Columns>       
        </telerik:RadGridView>

and in the viewmodel I've :

        public void test()
        {
            _windowManager.ShowWindow(new ReportViewModel(_repository));
        }

The event is not fired... I've tried both to put x:name on the Button and in the GridViewDataColumn...
What am I doing wrong?

Thanks

Michele
Top achievements
Rank 2
 asked on 22 Nov 2011
1 answer
61 views
Hi,
I have a gridview having a grid in its rowdetail, when row detail visibility changes i fetch data from database to load the row detail grid.
But the problem here is that when i sort or filter on the main grid, the data is removed from the already opened row detail grid.

Same thing happens when we have some controls in our rowdetails, and the values of expanded row details sets to blank when filtered or sorted.

Using "RowDetailsVisibilityChangedevent" to populate the rowdetails, due to some constraints not using "LoadingRowDetails".

Please let me know is there anything i can do so that those row detail grid data does not get removed when I do sorting or filtering on main grid.

Please reply its urgent.
Thanks
Manishkumar
Top achievements
Rank 1
 answered on 22 Nov 2011
1 answer
216 views

Hello,
The BusyIndicator works very well, but one small detail that I don’t like. Let's see if I can help:
When I apply BusyIndicator on a RadGridView  the text color from the rows of RadGridView turns from gray tone Metro (My default template) to color black.

this is my code:

<telerik:RadBusyIndicator IsBusy="{Binding Cargando}" BusyContent="Cargando">
                                <telerik:RadGridView Focusable="False" telerik:PersistenceManager.StorageId="RGrid" Grid.Row="0" AutoGenerateColumns="False" x:Name="radGridView1" ItemsSource="{Binding Conocimientos}" SelectedItem="{Binding ConocimientoSeleccionado}" CanUserInsertRows="False" CanUserDeleteRows="False" IsManipulationEnabled="False" IsReadOnly="True">
                                    <i:Interaction.Triggers>
                                        <i:EventTrigger EventName="MouseDoubleClick">
                                            <ei:CallMethodAction MethodName="radGridView1_MouseDoubleClick" TargetObject="{Binding}" />
                                        </i:EventTrigger>
                                    </i:Interaction.Triggers>
                                    <telerik:RadGridView.Columns>
                                        <telerik:GridViewDataColumn MinWidth="0" Name="ColIdConocimiento" DataMemberBinding="{Binding IdConocimiento}" Header="{Binding TAAF_Gestiones_Presentation_WPF_ConocimientosLista_ColIdConocimiento_Header,Source={StaticResource resLanguage}}" Width="60" />
                                        <telerik:GridViewDataColumn MinWidth="0" Name="ColFecha" DataMemberBinding="{Binding Fecha}" Header="{Binding TAAF_Gestiones_Presentation_WPF_ConocimientosLista_ColFecha_Header,Source={StaticResource resLanguage}}" Width="80" DataFormatString="{}{0: dd/MM/yyyy}" />
                                        <telerik:GridViewDataColumn MinWidth="0" Name="ColPregunta" DataMemberBinding="{Binding Pregunta}" Header="{Binding TAAF_Gestiones_Presentation_WPF_ConocimientosLista_ColPregunta_Header,Source={StaticResource resLanguage}}" Width="200" />
                                        <telerik:GridViewDataColumn MinWidth="0" Name="ColRespuesta" DataMemberBinding="{Binding Respuesta}" Header="{Binding TAAF_Gestiones_Presentation_WPF_ConocimientosLista_ColRespuesta_Header,Source={StaticResource resLanguage}}" Width="200" />
                                        <telerik:GridViewDataColumn MinWidth="0" Name="ColIdAplicacion" DataMemberBinding="{Binding IdAplicacion}" Header="{Binding TAAF_Gestiones_Presentation_WPF_ConocimientosLista_ColIdAplicacion_Header,Source={StaticResource resLanguage}}" Width="40" />
                                        <telerik:GridViewDataColumn MinWidth="0" Name="ColAplicacion" DataMemberBinding="{Binding Aplicacion}" Header="{Binding TAAF_Gestiones_Presentation_WPF_ConocimientosLista_ColAplicacion_Header,Source={StaticResource resLanguage}}" Width="150" />
                                        <telerik:GridViewDataColumn MinWidth="0" Name="ColIdAplicacionModulo" DataMemberBinding="{Binding IdAplicacionModulo}" Header="{Binding TAAF_Gestiones_Presentation_WPF_ConocimientosLista_ColIdAplicacionModulo_Header,Source={StaticResource resLanguage}}" Width="40" />
                                        <telerik:GridViewDataColumn MinWidth="0" Name="ColAplicacionModulo" DataMemberBinding="{Binding AplicacionModulo}" Header="{Binding TAAF_Gestiones_Presentation_WPF_ConocimientosLista_ColAplicacionModulo_Header,Source={StaticResource resLanguage}}" Width="150" />
                                    </telerik:RadGridView.Columns>
                                </telerik:RadGridView>
                                </telerik:RadBusyIndicator>


Someone can tell me the reason?
Thanks and sorry for my English

Yana
Telerik team
 answered on 22 Nov 2011
3 answers
125 views
The RadDataPager works great for us, especially when it comes to speeding up the loading time for our records on the main page of our app (we were loading all of our records at the same time before, and there are a lot of them).

However, is it possible to sort data across pages when you're using the RadDataPager? Currently, when a user clicks on a column header in the RadGridView, it just sorts the records on that page. Would there be a way to sort all of the records across all pages when a user clicks a column header?

I'm assuming that we'll have to implement our own custom logic to get this to work, and I'm also assuming that we won't be able to get around the fact that we'll have to load all of the records in the gridview again, but I'm just wondering if anyone has found an efficient way to do this.

Thanks!

Rossen Hristov
Telerik team
 answered on 22 Nov 2011
5 answers
157 views
The standard WPF Richtextbox supports pasting of ImageData. Is there a way to get this working with the RadRichTextBox?
Iva Toteva
Telerik team
 answered on 22 Nov 2011
1 answer
121 views
I need to make the RadMap pan left/right/up/down based on some non-ui events.  How do I tell the map to pan programatically? Which property do I use?  Is there a RoutedUICommand or something?

I had to do the same thing for zooming and that was pretty easy.  I've found the PanningCompleted event, but don't know where the Pan function is :)  Please point me in the right direction.
Andrey
Telerik team
 answered on 22 Nov 2011
1 answer
455 views
Hi,

I'm currently using the RadDocking control in a project.
It's a fairly simple layout with dockable panes on the left of the screen and a document host filling up the rest of the space.

In order to track down this issue I only have 2 panes in the pane group for now.

What I'm trying to do is assign short cut keys to each of the panes.
Specifically, when you press the short cut key for a particular pane that pane will become active and the focus will be on the first control in the pane.

I've defined some RoutedUICommands and used Windows.InputBindings to assign short cut keys to the commands.
The Executed handler for each command does the following:
1. Sets the Selected Item property of the RadPaneGroup to the appropriate pane.
2. Calls control.Focus() on the appropriate control (within that pane).

Unfortunately, this isn't working as it should.

Ridiculously, I've found that by calling DoEvents() in between setting the selected item and setting the focus of the control it works as it should. I know C# doesn't officially have a DoEvents method but if you google it you'll find examples of code that looks like this:

Application.Current.Dispatcher.Invoke(DispatcherPriority.Background, new Action(delegate { }));


Obviously, this is a hack and I'm keen to fix it the right way.

Any help would be appreciated, I have a sample application which illustrates the point if needed.

Thanks,


CA.


Ivo
Telerik team
 answered on 22 Nov 2011
8 answers
404 views
Hi,

I want to know the equivalent mecanism in WPF to bind Property  of the TreeView and TreeViewItems with properties in the ViewModel using MVVM pattern. For Example in silverlight  I do such and work perfectly:

<telerik:ContainerBindingCollection x:Name="BindingProperties">
   <telerik:ContainerBinding PropertyName="IsLoadOnDemandEnabled" Binding="{Binding Path=Expand, Mode=TwoWay}" />
 <telerik:ContainerBinding PropertyName="IsDropAllowed" Binding="{Binding Path=DropAllowed, Mode=TwoWay}"/>
</telerik:ContainerBindingCollection>

But this one doesn t work in WPF. Can U tell me how to adapt this in the WPF context??

Thank U for your Help

Alino
Tina Stancheva
Telerik team
 answered on 22 Nov 2011
1 answer
185 views

I dynamically built a form using a RadDocking, then a Vertical RadSplitContainer and inside the RadSpltContainer two Horizontal RadSplitContainers. The lower RadSplitContainer has three RadPaneGroups where the right outer contains three RadPanes.
The right outer container is filled like this:

radPaneGroupSystem.AddItem(ucStatusAlarms, Telerik.Windows.Controls.Docking.DockPosition.Top);
radPaneGroupSystem.AddItem(ucRSSFeed, Telerik.Windows.Controls.Docking.DockPosition.Left);
radPaneGroupSystem.AddItem(ucMessageViewer, Telerik.Windows.Controls.Docking.DockPosition.Right);

If I do that I get a "Object reference not set to an instance of an object." error, source "Telerik.Windows.Controls.Docking",
StackTrace   
at Telerik.Windows.Controls.RadPaneGroup.GetPaneGroup()
at Telerik.Windows.Controls.RadPaneGroup.AddItem(RadPane pane, DockPosition dockPosition)

If I change the code and use panegroupParent.Items.Add(ucStatusAlarms), etc I get the three RadPanes as three Tabs functioning normally.

I checked the parameters going into the AddItem call, they are normally set to an instance.
Does anyone know why the Docking gives an Object reference not set to an instance of an object error and what I can do about it?

Pieter
Top achievements
Rank 2
 answered on 22 Nov 2011
1 answer
168 views
Hi,

I am using MaskedInput control for currency value. I want to set a negative currency value in the masked input control. I get () in the control when I type - symbol. How to set mask which accepts negative value for currency type.

Regards,
Jeyakumar
Petar Mladenov
Telerik team
 answered on 22 Nov 2011
Narrow your results
Selected tags
Tags
+? more
Top users last month
Anislav
Top achievements
Rank 6
Silver
Bronze
Bronze
Jianxian
Top achievements
Rank 1
Iron
Marco
Top achievements
Rank 3
Iron
Iron
Iron
Jim
Top achievements
Rank 2
Iron
Iron
Nurik
Top achievements
Rank 2
Iron
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Anislav
Top achievements
Rank 6
Silver
Bronze
Bronze
Jianxian
Top achievements
Rank 1
Iron
Marco
Top achievements
Rank 3
Iron
Iron
Iron
Jim
Top achievements
Rank 2
Iron
Iron
Nurik
Top achievements
Rank 2
Iron
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?