public MainWindow(){ InitializeComponent(); this.radGridView1.ItemsSource = GenerateProducts(); this.radGridView2.ItemsSource = GenerateProducts(); MessageBox.Show(radGridView1.Items.Count.ToString()); MessageBox.Show(radGridView2.Items.Count.ToString());}<UserControl.Resources> <BooleanToVisibilityConverter x:Key="booleanConverter" /> <selectors:MenuItemTemplateSelector x:Key="templateSelector"></selectors:MenuItemTemplateSelector> <HierarchicalDataTemplate x:Key="MenuItemTemplate" ItemsSource="{Binding Items}"> <TextBlock Text="{Binding Text}" cal:Action.TargetWithoutContext="{Binding}" Visibility="{Binding IsVisible,Mode=TwoWay,Converter={StaticResource booleanConverter}}" /> </HierarchicalDataTemplate> </UserControl.Resources> <Grid> <telerik:RadMenu x:Name="MenuList" ClickToOpen="False" BorderBrush="Transparent" ItemsSource="{Binding Items}" ItemTemplate="{StaticResource MenuItemTemplate}" cal:Message.Attach="[Event ItemClick] = [Action OpenView($eventArgs)]" > <telerik:RadMenu.ItemContainerStyle> <Style TargetType="telerik:RadMenuItem"> <Setter Property="IsSeparator" Value="{Binding IsSeparator}" /> <Setter Property="IsChecked" Value="{Binding IsChecked, Mode=TwoWay}" /> <Setter Property="IsCheckable" Value="{Binding IsCheckable}" /> <Setter Property="StaysOpenOnClick" Value="{Binding IsCheckable}" /> </Style> </telerik:RadMenu.ItemContainerStyle> </telerik:RadMenu> </Grid></UserControl>Hi there,
We have identified a bug with the RadPane/RadDocking control's maximize functionality, which we would appreciate your feedback on as soon as possible.
When maximizing a floating RadPane on a secondary display that has a resolution greater (1920*1200) than that of the primary display (1600*1200) the RadPane is not sized to the extent of the display, but extends beyond it. This is only the case when the resolutions of the displays are setup in this way; if the primary screen has the greater resolution it does not occur. Unfortunately this is a usual setup for laptop users who have a large display available when they are working in the office.
However, we have resolved this issue (or very similar) in the past in some of our own window management code, so may be able to offer a potential resolution. We experienced the same symptoms in our custom windows as a result of using a WindowStyle of None and then using Win32 interop to set the minmaxinfo appropriately to avoid overlapping the Windows TaskBar. The calculations for some reason became invalid in the scenario described above. The solution implemented was simply not to adjust the minmaxinfo when the window was found to be not on the primary screen.
Looking forward to your feedback,
Chris
<TelerikGW:RadGridView x:Name="radGridView" Grid.Row="2" ItemsSource="{Binding SearchResult.Results}" ScrollViewer.HorizontalScrollBarVisibility="Visible" MinWidth="50" HorizontalAlignment="Stretch" > <TelerikGW:RadGridView.Columns> <TelerikGW:GridViewDataColumn Width="*" MinWidth="50"> <TelerikGW:GridViewDataColumn.Header> <Label Content="Found" /> </TelerikGW:GridViewDataColumn.Header> <TelerikGW:GridViewColumn.CellTemplate> <DataTemplate> <StackPanel Margin="0" HorizontalAlignment="Left" VerticalAlignment="Top" Orientation="Horizontal" > <StackPanel.InputBindings> <MouseBinding Command="{Binding Path=ResultClick}" MouseAction="LeftDoubleClick" /> </StackPanel.InputBindings> <Image Height="20" MaxWidth="100" Margin="0" Source="{Binding ClassIcon.ContentBytes}" Stretch="Uniform" /> <WV:TextHighLighter Margin="10" ToolTip="{Binding ResultItem.MatchTerm}" Padding="0" Text="{Binding Path=ResultItem.MatchTerm}" TextToHighLight="{Binding DataContext.SearchedTerm, RelativeSource={RelativeSource AncestorType=WV:GlobalSearch}}" /> </StackPanel> </DataTemplate> </TelerikGW:GridViewColumn.CellTemplate> </TelerikGW:GridViewDataColumn> </TelerikGW:RadGridView.Columns></TelerikGW:RadGridView>
[System.InvalidCastException] = {"Unable to cast object of type 'System.Windows.Documents.Run' to type 'System.Windows.FrameworkElement'."}Message = "Unable to cast object of type 'System.Windows.Documents.Run' to type 'System.Windows.FrameworkElement'."Source = "Telerik.Windows.Controls.GridView"StackTrace = " at Telerik.Windows.Controls.GridView.GridViewRow.ShouldHandleMouseDoubleClick(MouseButtonEventArgs e)\r\n at Telerik.Windows.Controls.GridView.GridViewRow.OnMouseDoubleClick(MouseButtonEventArgs e)\r\n at System.Windows.Controls.Control.HandleDouble...
<telerikDocking:RadDocking.DocumentHost> <telerikDocking:RadSplitContainer> <telerikDocking:RadPaneGroup x:Name="radDockingDocumentHost" /> </telerikDocking:RadSplitContainer></telerikDocking:RadDocking.DocumentHost>private void btnBlankNewOrder_Click(object sender, RoutedEventArgs e){ //ADD NEW DOCUMENT PANE _ RadRichTextBox var pane = new RadRichTextBoxAutoComplete(products); pane.Title = "Rob's Test Pane"; radDockingDocumentHost.Items.Add(pane);}<telerik:RadDocumentPane x:Class="TAS2.RadRichTextBoxAutoComplete" xmlns:telerikDocking="clr-namespace:Telerik.Windows.Controls;assembly=Telerik.Windows.Controls.Docking" xmlns:telerikQuickStart="clr-namespace:Telerik.Windows.Controls.QuickStart;assembly=Telerik.Windows.Controls" xmlns:telerik="http://schemas.telerik.com/2008/xaml/presentation" mc:Ignorable="d">.................MY CONTROL CONTENT HERE (Cut Out for this Example) ...................</telerik:RadDocumentPane><telerik:RadDocumentPane x:Class="TAS2.RadRichTextBoxAutoComplete" ..... > <Grid> <Grid.ColumnDefinitions> <ColumnDefinition /> <ColumnDefinition /> </Grid.ColumnDefinitions> <!-- RichTextBox --> <telerik:RadRichTextBox x:Name="radRichTextBox" AcceptsReturn="True" Width="800" Margin="10" Padding="10" Grid.Column="0" FontSize="14" IsSpellCheckingEnabled="False" DocumentInheritsDefaultStyleSettings="True" /> </Grid></telerik:RadDocumentPane>