Telerik Forums
UI for WPF Forum
2 answers
819 views

Hello,
I'm doing a generic UserControl so I have no idea of the number of columns and their names. This is the reason why I'm using GridViewHeaderRow instead of GridVIewHeaderCell. My columns are AutoGenerated.
The main is that : 
I edit the style like this => 

        <Style x:Key="HeaderRowStyle" TargetType="telerik:GridViewHeaderRow">
            <Setter Property="Background" Value="#FF606366"></Setter>
            <Setter Property="FontWeight" Value="Medium"></Setter>
        </Style>

I need to as this background on the mouse over the header.

I tried a few things like using the Setter of the property template and using the Trigger of IsMouseOver but it's not working.
Perhaps the trigger was the good solution and I was just missing a few properties? 
Thanks in advance

Martin Ivanov
Telerik team
 answered on 10 Jan 2022
1 answer
222 views

Is there an option to use filters, column filters, sorting and/or searching in the WPF RadGanttView? 

It would be very handy for bigger plans in the GanttView to find stuff, or get a better overview and so on.

Martin Ivanov
Telerik team
 answered on 10 Jan 2022
1 answer
174 views

I have a RadGanttView in which you can change the task in the columns. So if I click into the cells I can edit the value in it. After the Editing I do a validation. If this validation fails, a errormessage is shown. If this message is showing, I have to set the wrong cell in edit mode. But I wasn't able to do that.

How can I set a specific cell to edit-mode by code?

 

I already tried so call the TaskEdititngEvent, but didn't work as  excpected:

var editingEventArgs = new TaskEditingEventArgs(RadGanttView.TaskEditingEvent, neuerTask);
GanttDiagramm.RaiseEvent(editingEventArgs);

Martin Ivanov
Telerik team
 answered on 07 Jan 2022
1 answer
251 views
Is there a way to control the visibility of the Content of a RadPathButton via some property?  From the documentation it seems not but the ControlTemplate makes it appear otherwise.

Background: I was looking into making a RadPathButton that would hide its content (and only show the PathGeometry) when it got small enough.  My idea was either to derive a class from this or to create a WPF Behavior that added a ContentVisibility  DependencyProperty to take care of this for me.  Then I would write my own style with my own ControlTemplate to honor this property

But when I looked at Telerik's ControlTemplate for RadPathButton (in the Windows8Touch theme) I saw a  reference to "ContentVisibilityStates" group in the VisualStateManager section that looked like what I need.  It has a Visible and Collapsed states.  If I could find a way to make the control enter the Collapsed state, it would collapse the content exactly as I desire.

However I cannot see any sort of property that binds to this.  So how is it changed?  Is it possible for me to bind some property to the button to make its content disappear when I need it to?
<VisualStateGroup x:Name="ContentVisibilityStates">
    <VisualState x:Name="Visible" />
    <VisualState x:Name="Collapsed">
        <Storyboard>
            <ObjectAnimationUsingKeyFrames Storyboard.TargetName="ContentHost"
                Storyboard.TargetProperty="Visibility">
                <DiscreteObjectKeyFrame KeyTime="0">
                    <DiscreteObjectKeyFrame.Value>
                        <Visibility>Collapsed</Visibility>
                    </DiscreteObjectKeyFrame.Value>
                </DiscreteObjectKeyFrame>
            </ObjectAnimationUsingKeyFrames>
        </Storyboard>
    </VisualState>
</VisualStateGroup>

Stenly
Telerik team
 answered on 06 Jan 2022
0 answers
224 views

Hello.

There are two gridviews.

These gridviews are connected 1:1 with the row.
So I'm done with the vertical scrolling synchronization.

All data is now displayed.
When I check here, I want to show the contents of the gridview on the other side.

When the GridView Checkbox Column is unchecked, I want to make it impossible to see the contents of the grid view on the other side.

This should be done with Rows only and not all data.

What method do you have?

I attach an example.

In case of additional scroll sync, it is written as a code-behind. Can you change this to MVVM pattern?(How to get 2 gridview parameters since EventToCommandBehavior event is loaded?)

Thanks.

Psyduck
Top achievements
Rank 5
Bronze
Bronze
Bronze
 updated question on 05 Jan 2022
0 answers
373 views

I'm having some real struggles with RadComboBox ... 


<telerik:RadComboBox x:Name="ModelPicker"
                                 Width="150"
                                 Height="28"
                                 CanAutocompleteSelectItems="False"
                                 DisplayMemberPath="ModelNavn"
                                 IsEditable="True"
                                 IsEnabled="{Binding CanChangeVariant}"
                                 ItemsSource="{Binding Source={StaticResource SortedModels}}"
                                 OpenDropDownOnFocus="True"
                                 SelectAllTextEvent="GotFocus"
                                 SelectedItem="{Binding BrandModel.SelectedCarModel}"
                                 StaysOpenOnEdit="True" />

 

1. ComboBox is AutoSelecting first element when ItemsSource changes

ItemsSource is set to an ObservableCollection<model> and the DataContext implements INotifyPropertyChanged (pretty straight forward MVVM) 

I've tested and found that if I REPLACE the ObservableCollection instead of Clear() + Add() , the UI update is MUCH faster. 

eg:

ItemsSource="{Binding MyModels}"

MyModels = new ObservableCollection<model>(/* List of Models */); 

HOWEVER - this causes the RadComboBox to AutoSelect the first element !!!

(to be fair - this is actually also how Microsoft WPF ComboBox works) ..  :-( 

 

2. CanAutocompleteSelectItems="False" is ignored

On almost every keystroke I do when AutoCompleting / Filtering - the ComboBox selects whatever item is partially matching 

eg : list contains 1000, 114i, 114 and 114d 

if I write "1" then 1000 is selected,

if I write "114d" and delete "d" then 114 gets selected. 

I'm pretty sure that CanAutoCompleteSelectItems=false should prevent this ??

 

 

Martin
Top achievements
Rank 2
Iron
Iron
Iron
 updated question on 04 Jan 2022
1 answer
230 views

Hello.

 

I'm trying to use the "Column Chooser" from the telerik SDK.

The SDK is in a state where both ID and Name can be controlled Visible.

I want to change a specific column to be fixed.

For example, ID and Name in the SDK example. I want only Name to be IsVisible, excluding ID from Listbox.
(ID is always shown)

Is it possible to simply control it in xaml? Or do I need extra work in the viewmodel?

I'm using the "declarative column definition method using the DataMemberBinding property set".

 

thanks.

 

Dilyan Traykov
Telerik team
 answered on 04 Jan 2022
0 answers
109 views

Hi,

I have tried sub-classing a RadSplitButton. But no functionalities is being inherited from the original button. So, there is no dropdown content showing (popup) when clicking on the dropdown button, Command gets not executed and so on.

Any suggestion on how to properly base a custom control on this Split button, please?

Avrohom
Top achievements
Rank 1
Iron
Iron
 updated question on 03 Jan 2022
1 answer
257 views

Hi

I created a main window with RadDocking with DocumentHost and some RadSplitContainer.
Now with a user interaction I show a modeless window: I'd like to give the user the ability to dock this window in main window as docking part.
In the first look example of RadDocking there is a initial floating RadSplitContainer, but I would that my floating part only show after the user click a button and it was initially hidden.

Also, if I close the initially visible flaoting part, then I can't reopen it.

This is the flow of visibility:
1) Launch the application: floating window is not visible
2) Click on some button: floating window is now visible
3) User can dock the floating window on mainwindow docking

This is the RadDocking piece of xaml:

<t:RadDocking x:Name="radDocking1"
                            RetainPaneSizeMode="DockingAndFloating"
                            CanAutoHideAreaExceedScreen="True"
                            Grid.Row="1" Margin="0 0 0 10"                            
                            BorderThickness="0"
							CloseButtonPosition="InPane"
                            Padding="0"
						  PaneStateChange="radDocking1_PaneStateChange">
<t:RadDocking.DocumentHost>
<some code>
</t:RadDocking.DocumentHost>
<t:RadSplitContainer>
<some code>
</t:RadSplitContainer>
<t:RadSplitContainer>
<some code>
</t:RadSplitContainer>
<some code>
<t:RadSplitContainer>
</t:RadSplitContainer>
<t:RadSplitContainer Name="ImpulsiFloatContainer" 
						InitialPosition="FloatingDockable"
						 t:DockingPanel.InitialSize="900,1340"									 
						 Visibility="{Binding ImpulsiViewVisible, Converter={StaticResource BoolToVis}}">
					<t:RadPaneGroup >
						<t:RadPane  Header="{DynamicResource ResourceKey={x:Static r:ResourcesKeys.ImpulsiViewHeader}}">
							<local:ImpulsiViewControl />
						</t:RadPane>
					</t:RadPaneGroup>
				</t:RadSplitContainer>
			</t:RadDocking>

Thank you

Luigi

 

Stenly
Telerik team
 answered on 03 Jan 2022
2 answers
325 views

I'm using a ChartSeriesProvider to display multiple LineSeries charts. Everything is working well except the legend items. I would like the Title property to display each series name, but instead I'm getting the same series name (the first one) for all of the legend titles.

If I do it via XAML it works, as shown in your example:

<Setter Property="LegendSettings">
  <Setter.Value>
    <telerik:SeriesLegendSettings x:Name="jobsLegendSettings" Title="{Binding SeriesName}" />
  </Setter.Value>
 </Setter>

However, I must do it via code behind. Here is my current code which doesn't work (I only pasted the relevant code, I hope it's enough):

Style style = new Style();
descriptor.Style = style;
jobsSeriesProvider.SeriesDescriptors.Add(descriptor);
style.TargetType = typeof(Telerik.Windows.Controls.ChartView.LineSeries);
Binding binding = new Binding();
binding.Path = new PropertyPath("SeriesName");
binding.Source = JobsData;
SeriesLegendSettings legendSettings = new SeriesLegendSettings();
BindingOperations.SetBinding(legendSettings, SeriesLegendSettings.TitleProperty, binding);

var legendSetter = new Setter
{
	Property = Telerik.Windows.Controls.ChartView.LineSeries.LegendSettingsProperty,
	Value = legendSettings,
};
style.Setters.Add(legendSetter);  
BTW JobsData is the ObservableCollection which contains all of the different series view models, which have a property called SeriesName.

 

Stenly
Telerik team
 answered on 31 Dec 2021
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?