Telerik Forums
UI for WPF Forum
1 answer
94 views

I'm having an issue where I sometimes get two groups with a key of empty string when I add a grouping to my data.

It's really important that these group keys be unique because I'm doing some fairly complicated grid navigation in hierarchical grids and I rely on that key being unique so I can programatically make decisions about where to move focus.

Is there a grouping maximum or something that I'm missing, or is this a Telerik bug?

Wesley
Top achievements
Rank 1
 answered on 16 Jul 2019
4 answers
163 views

Hi,

I have following style applied for all my RadMultiColumnComboBox controls (in the app.xaml):

<!--Telerik default DefaultTelerikRadMultiColumnComboBoxStyle-->
<Style x:Key="DefaultTelerikRadMultiColumnComboBoxStyle" TargetType="telerik:RadMultiColumnComboBox" BasedOn="{StaticResource RadMultiColumnComboBoxStyle}">
    <!--<Setter Property="SelectionMode" Value="Single"/>-->
    <Setter Property="AutoCompleteMode" Value="Search"/>
    <Setter Property="FontFamily" Value="{StaticResource DefaultFont}"/>
    <Setter Property="FontSize" Value="{StaticResource DefaultFontSize}"/>
    <Setter Property="FontWeight" Value="{StaticResource DefaultFontWeight}"/>
    <Setter Property="MinHeight" Value="{StaticResource DefaultMinimumHeight}"/>
    <Setter Property="KeepDropDownOpen" Value="False"/>
    <Setter Property="CloseDropDownAfterSelectionInput" Value="True"/>
    <Setter Property="SelectionBoxesVisibility" Value="Visible"/>
 
    <Setter Property="Validation.ErrorTemplate" Value="{StaticResource ErrorTemplate}"/>
 
    <Style.Triggers>
        <Trigger Property="IsEnabled" Value="True">
            <Setter Property="Background" Value="{StaticResource DefaultTextBoxBackgroundColor}"/>
        </Trigger>
        <Trigger Property="IsEnabled" Value="False">
            <Setter Property="Background" Value="Red"/>
        </Trigger>
        <Trigger Property="IsFocused"  Value="True">
            <Setter Property="Background"  Value="{StaticResource DefaultTextBoxIsFocusedBackgroundColor}"/>
        </Trigger>
    </Style.Triggers>
</Style>
<Style TargetType="{x:Type telerik:RadMultiColumnComboBox}" BasedOn="{StaticResource DefaultTelerikRadMultiColumnComboBoxStyle}"/>

 

With this style applied, I get this error in my XAML files (see attached file): The element "[RadMultiColumnComboBox]" could not be displayed because of a problem with System.Windows.StaticResourceExtension: CollectionView must have value. Parameter name: collectionView.

The error is provoced by the setter of the AutoCompleteMode.  The error disappears when this setter is deleted.

Setting the AutoCompleteMode directly on a RadMultiColumnComboBox (with the style applied) does not cause any problems.

Any ideas ??

Regards,
Hans

 

 

 

Martin Ivanov
Telerik team
 answered on 16 Jul 2019
6 answers
422 views

In your standard TreeListView sample program, ExpandItemsIntoView, scrolling stops working if I add drag-and-drop parameters as follows:

        <telerik:RadTreeListView x:Name="RadTreeListView1" 

                                 GroupRenderMode="Flat" 
                                 ItemsSource="{Binding}" 
                                 Grid.Row="1"
                                 telerik:DragDropManager.AllowDrag="True"
                                 telerik:DragDropManager.AllowCapturedDrag="True">

Is that a problem with the control, or is something else needed to ensure scrolling works? I have this problem in a much more complex example, but I was able to reproduce it in your sample. 

Georg
Top achievements
Rank 1
Veteran
 answered on 16 Jul 2019
4 answers
245 views

Hello

I'm trying to add a picture to a spreadsheet. There is not problement to add the picture, but I'm trying to center it into a merge cell and I can't get the size.

I did the code bellow :

Private Sub addLogo(ByRef worksheet As Worksheet, ByVal columnCount As Integer, ByVal rowCellIndex As Integer, ByVal columnCellIndex As Integer)
 
            Dim image As New FloatingImage(worksheet, New CellIndex(columnCellIndex, rowCellIndex), 0, 0)
 
            Using stream As Stream = Assembly.GetExecutingAssembly().GetManifestResourceStream(String.Concat(Assembly.GetExecutingAssembly().GetName().Name, ".MyLogo.png"))
                image.ImageSource = New ImageSource(stream, "png")
                image.LockAspectRatio = True
                Dim ratio As Double = worksheet.Rows(rowCellIndex).GetHeight().Value.Value / image.Height
                image.Height = image.Height * ratio
                image.Width = image.Width * ratio
                image.OffsetX = worksheet.Columns(columnCellIndex, columnCellIndex + columnCount - 1).GetWidth().Value.Value - image.Width
            End Using
 
            worksheet.Shapes.Add(image)
 
        End Sub

the worksheet.Rows(rowCellIndex).Getheight().Value.Value return 20 each time, unless the row is highter

and the worksheet.Columns(columnCellIndex, columnCellIndex + columnCount - 1).GetWidth().Value.Value return 65 each time, for one or more column.

So I don't know the right command to get the height and width of my merge cell, could you help me ?

Thanks

J-Christophe

 

Nikolay Demirev
Telerik team
 answered on 16 Jul 2019
1 answer
201 views

Hi team,

Let's say I have a set of shapes selected, a unique bounding box including all selected shapes is rendered.
is it possible to hide the bounding box? Or is it possible to customize the highligh of the single selected shapes?

I attached a sample picture (taken from powerpoint)

Thanks in advance

Dinko | Tech Support Engineer
Telerik team
 answered on 16 Jul 2019
3 answers
115 views

Hi Progress Team,

I added a RadCalendar component to my project but when changing the base week of this 2x2 grid calendar the weeknumbers stay the same all the time. Have I missed something here? How do they update? I used the following code for the XAML definition:

<telerik:RadCalendar
    Grid.Column="0"
    Margin="36,10,10,10"
    AreWeekNamesVisible="True"
    AreWeekNumbersVisible="True"
    CalendarWeekRule="FirstFourDayWeek"
    Columns="2"
    Culture="de-DE"
    DateSelectionMode="Day"
    FirstDayOfWeek="Monday"
    Foreground="White"
    Rows="2"
    SelectionMode="Extended"
    ViewsHeaderVisibility="Visible">
</telerik:RadCalendar>
Martin Ivanov
Telerik team
 answered on 16 Jul 2019
1 answer
253 views

Hello!

We've recently started replacing standard WPF controls with their Telerik counterparts in our project and we've noticed that Telerik menu items are not visible at design time where the standard WPF menu items are. Is this a bug?

 

Vicky
Telerik team
 answered on 16 Jul 2019
2 answers
692 views

I am working on some legacy code, I have RadTreeView with Item template which expand the hierarchy at doubleclick, I want to add a contextmenu which expand the hierarchy in the same way, problem is that there is no command to bind to expand nodes. How can I have the context menu work in the same way as the itemtemplate?

 

<p></p><p>                <telerik:RadTreeView Grid.Row="2" Background="White" BorderBrush="DarkGray" BorderThickness="1" VerticalAlignment="Stretch"<br>
                                         Name="ResultSetReportTreeView"<br>
                                         IsVirtualizing="True" <br>
                                         ItemDoubleClick="RadTreeViewItemDoubleClick"<br>
                                         Width="{Binding ElementName=GuideControl, Path=ActualWidth}"<br>                                         ItemContainerStyle="{StaticResource ResourceKey=HierarchyTreeViewStyle}"<br>                                         SelectedItem="{Binding Path=SelectedNode, Mode=TwoWay}"<br>
                                       ItemsSource="{Binding ResultSetReportNodes}"<br>
                                         SelectionMode="Single" ><br>
                    <br>                    <telerik:RadTreeView.Resources><br>
                        <Style TargetType="{x:Type telerik:RadTreeViewItem}"><br>
                            <Setter Property="IsExpanded" Value="{Binding Path=IsExpanded, Mode=TwoWay}" /><br>
                        </Style><br>
                    </telerik:RadTreeView.Resources><br>
                    <telerik:RadTreeView.ItemTemplate><br>
                        <HierarchicalDataTemplate ItemsSource="{Binding Path=Children}"><br>
                            <StackPanel Orientation="Horizontal" Background="Transparent" ToolTip="{Binding Path=Name, Mode=OneWay}"><br>
                                <Image Style="{StaticResource ResourceKey=IconStyle}" VerticalAlignment="Center" Margin="5,0,0,0"/><br>
                                <TextBlock Text="{Binding Path=Name}" ToolTip="{Binding Path=Name, Mode=OneWay}" Margin="5,0,0,0"/><br>
 <!--start of my Context menu--><br>
                                <StackPanel.ContextMenu><br>
                                    <ContextMenu><br>                                        <!--ExpandAllDescendantFoldersCommand IsCheckable=" empty I need it to work as itemtemplate does at doubleclick"--><br>                                        <MenuItem Header="{localization:Resx ResxName=Palantir.CommonResources.ButtonLabels, Key=Expand}" Command="{Binding Path=PlacementTarget.Tag.ExpandAllDescendantFoldersCommand, RelativeSource={RelativeSource Mode=FindAncestor, AncestorType={x:Type ContextMenu}}, Mode=OneWay}"><br
                                      </MenuItem><br>
                                    </ContextMenu><br>
                                </StackPanel.ContextMenu><br>
                            </StackPanel><br>
 <!--End of my Context menu--><br>
                        </HierarchicalDataTemplate><br>
                    </telerik:RadTreeView.ItemTemplate><br>
                </telerik:RadTreeView><br>
            </Grid><br>
        </telerik:RadExpander><br></p>

 

Ignazio
Top achievements
Rank 1
 answered on 15 Jul 2019
4 answers
1.7K+ views

Hello,

I have the following requirements:

  • When the user enters from outside the grid into the empty grid a new row should be created and the second cell should be selected in edit mode.
  • When the user enters from outside the grid into a grid with existing rows, the second cell should be selected in edit mode.

I am using the enter-key to move to the next field in a particular viewmodel, instead of the tab-key.

How can I accomplish this, I tried searching a solution but couldnt find anything that accomplish this when entering the grid from outside?

 

Any help would be greatly appreciated.

Marcel

Ras Ran
Top achievements
Rank 2
Iron
Veteran
Iron
 answered on 15 Jul 2019
4 answers
4.1K+ views

Hi, 

I'm trying to set the background color for a disabled MultiColumnComboBox using a style, without succes.  Here's my code

<Style x:Key="DefaultTelerikRadMultiColumnComboBoxStyle" TargetType="telerik:RadMultiColumnComboBox" BasedOn="{StaticResource RadMultiColumnComboBoxStyle}">
    <Setter Property="FontFamily" Value="{StaticResource DefaultFont}"/>
    <Setter Property="FontSize" Value="{StaticResource DefaultFontSize}"/>
    <Setter Property="FontWeight" Value="{StaticResource DefaultFontWeight}"/>
    <Setter Property="MinHeight" Value="{StaticResource DefaultMinimumHeight}"/>
    <Setter Property="KeepDropDownOpen" Value="False"/>
    <Setter Property="CloseDropDownAfterSelectionInput" Value="True"/>
    <Setter Property="SelectionBoxesVisibility" Value="Visible"/>
 
    <Setter Property="Validation.ErrorTemplate" Value="{StaticResource ErrorTemplate}"/>
 
    <Style.Triggers>
        <Trigger Property="IsEnabled" Value="True">
            <Setter Property="Background" Value="{StaticResource DefaultTextBoxBackgroundColor}"/>
        </Trigger>
        <Trigger Property="IsEnabled" Value="False">
            <Setter Property="Background" Value="WhiteSmoke"/>
        </Trigger>
        <Trigger Property="IsFocused"  Value="True">
            <Setter Property="Background"  Value="{StaticResource DefaultTextBoxIsFocusedBackgroundColor}"/>
        </Trigger>
    </Style.Triggers>
</Style>
<Style TargetType="{x:Type telerik:RadMultiColumnComboBox}" BasedOn="{StaticResource DefaultTelerikRadMultiColumnComboBoxStyle}"/>

 

Any ideas ?

Regards
Hans

Dimitar Dinev
Telerik team
 answered on 15 Jul 2019
Narrow your results
Selected tags
Tags
GridView
General Discussions
Chart
RichTextBox
Docking
ScheduleView
ChartView
TreeView
Diagram
Map
ComboBox
TreeListView
Window
RibbonView and RibbonWindow
PropertyGrid
DragAndDrop
TabControl
TileView
Carousel
DataForm
PDFViewer
MaskedInput (Numeric, DateTime, Text, Currency)
AutoCompleteBox
DatePicker
Buttons
ListBox
GanttView
PivotGrid
Spreadsheet
Gauges
NumericUpDown
PanelBar
DateTimePicker
DataFilter
Menu
ContextMenu
TimeLine
Calendar
Installer and Visual Studio Extensions
ImageEditor
BusyIndicator
Expander
Slider
TileList
PersistenceFramework
DataPager
Styling
TimeBar
OutlookBar
TransitionControl
FileDialogs
Book
ToolBar
ColorPicker
TimePicker
MultiColumnComboBox
SyntaxEditor
VirtualGrid
Wizard
ExpressionEditor
NavigationView (Hamburger Menu)
WatermarkTextBox
DesktopAlert
BarCode
SpellChecker
DataServiceDataSource
EntityFrameworkDataSource
RadialMenu
ChartView3D
Data Virtualization
BreadCrumb
LayoutControl
ProgressBar
Sparkline
TabbedWindow
ToolTip
CloudUpload
ColorEditor
TreeMap and PivotMap
EntityFrameworkCoreDataSource (.Net Core)
HeatMap
Chat (Conversational UI)
VirtualizingWrapPanel
Calculator
NotifyIcon
TaskBoard
TimeSpanPicker
BulletGraph
Licensing
WebCam
CardView
DataBar
FilePathPicker
PasswordBox
SplashScreen
Callout
Rating
Accessibility
CollectionNavigator
Localization
AutoSuggestBox
Security
VirtualKeyboard
HighlightTextBlock
TouchManager
StepProgressBar
Badge
OfficeNavigationBar
ExpressionParser
CircularProgressBar
SvgImage
PipsPager
SlideView
AI Coding Assistant
+? more
Top users last month
Cynthia
Top achievements
Rank 1
Iron
Toby
Top achievements
Rank 3
Iron
Iron
Iron
Danielle
Top achievements
Rank 1
Iron
Iron
Joel
Top achievements
Rank 3
Bronze
Bronze
Iron
yw
Top achievements
Rank 2
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Cynthia
Top achievements
Rank 1
Iron
Toby
Top achievements
Rank 3
Iron
Iron
Iron
Danielle
Top achievements
Rank 1
Iron
Iron
Joel
Top achievements
Rank 3
Bronze
Bronze
Iron
yw
Top achievements
Rank 2
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?