Telerik Forums
UI for WPF Forum
3 answers
157 views
Hi,

I added a new command into PaneHeader & RadPane. It works perfectly. I try to add this command into the toolwindow control template. Here the code:

<ControlTemplate x:Key="ToolWindowControlTemplate" TargetType="telerik:ToolWindow">
       <Border x:Name="VisualRoot" BorderThickness="{TemplateBinding BorderThickness}" BorderBrush="{TemplateBinding BorderBrush}" Background="{TemplateBinding Background}" >
           <Grid>
               <Grid.RowDefinitions>
                   <RowDefinition Height="Auto" MinHeight="22" />
                   <RowDefinition Height="*" />
               </Grid.RowDefinitions>
               <Grid.ColumnDefinitions>
                   <ColumnDefinition Width="*" />
                   <ColumnDefinition Width="Auto" />
               </Grid.ColumnDefinitions>
             
 
               <!-- Here, the new command on TOOLWINDOW-->
               <StackPanel Grid.Column="1" Orientation="Horizontal">
                   <telerik:RadButton x:Name="SettingsAction"                                   
                                  Command="local:RadDockingCommands.OpenSettingsCommand"
                                  BorderThickness="0"
                                  Height="20"
                                  Width="20"
                                  Background="Red"
                                  Content="Button"
                                  ToolTip="Open settings">
                   </telerik:RadButton>
                   <telerik:RadButton x:Name="CloseButton"  Command="telerik:WindowCommands.Close" Margin="0 0 4 0" Content="CLOSE THIS WINDOW" />
               </StackPanel>
               <ContentPresenter x:Name="Content" Margin="{TemplateBinding Padding}" Grid.Row="1" Grid.ColumnSpan="2" Content="{TemplateBinding Content}" />
           </Grid>
       </Border>
   </ControlTemplate>


The button is visible but the command is disable. I try to force the OnOpenSettingsCanExecute to true without success. I test also the PaneHeaderMenuOpen command and this command is enable.

Do you have a solution?

Thanks for reply.
Kalin
Telerik team
 answered on 15 Sep 2014
4 answers
113 views
Hello there,

I encountered a problem with my ScheduleView. I have customized the appointments using a new class inheriting from the appointment class and I also use my own edit-appointment and new-appointment dialog, which is shown, when the user doubleclicks into the ScheduleView oder clicks on a seperate button outside the ScheduleView, instead of the Telerik one.

The point I do not understand is: When I click on the button and not into the ScheduleView, using the same method that would be used if I click directly into the ScheduleView, it displays the modified appointment instant. If I doubleclick into the ScheduleView and edit the selected appointment, it still displays the old (unmodified) appointment.

This problem only occurs when editing an appointment.

Regards
Yana
Telerik team
 answered on 15 Sep 2014
3 answers
124 views
Hi,

I'm trying to apply a custom style on my ScheduleView but when there is a Style="{DynamicResource RadScheduleViewStyle1}" in the RadScheduleView arguments, i am losing the Day, Week, etc in the ScheduleViewHeader.

I have edited the template of the ScheduleView by right clicking on the scheduleView -> edit Template -> Edit Copy...

I've put the template in another xaml, ScheduleViewTemplate.xaml.
There was an error with DraggedItemsSource, but I corrected it with this thread: http://www.telerik.com/forums/custom-appointment-problem-since-3-1116-1040 

Can you help me to resolve the issue with the ViewDefinitions.
Thank you

 Here is my MainWindow.xaml:

<Window x:Class="WpfApplication1.MainWindow"
        xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
        xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
        xmlns:telerik="http://schemas.telerik.com/2008/xaml/presentation"
        Title="MainWindow" Height="550" Width="625">
    <Window.Resources>

        <ResourceDictionary>
            <ResourceDictionary.MergedDictionaries>
                <ResourceDictionary Source="ScheduleViewTemplate.xaml" />
            </ResourceDictionary.MergedDictionaries>
        </ResourceDictionary>

    </Window.Resources>
    <Grid>
        <telerik:RadScheduleView x:Name="sv" Height="Auto" Style="{DynamicResource RadScheduleViewStyle1}">
            <telerik:RadScheduleView.ViewDefinitions>
                <telerik:DayViewDefinition />
                <telerik:WeekViewDefinition/>
                <telerik:MonthViewDefinition/>
                <telerik:TimelineViewDefinition/>
            </telerik:RadScheduleView.ViewDefinitions>
        </telerik:RadScheduleView>
    </Grid>
</Window>
Yana
Telerik team
 answered on 15 Sep 2014
1 answer
44 views
Hello,

I am implementing a WPF-Application that contains a GridView with Rowdetails with RowDetails, where a field is a mandatory input.
Therefore I have two issues to solve:
1. If I typing in the row cell the corresponding field in the row details will not updatet immediately. It is only updated when I press the Enter key. How could I achieve a syncrones update of RowDetails?
2. The mandatory field is filled, I click with the mouse in the RowDetails field (eg textbox). The GridView do not realize that the row cell is no longer edited (I think CellEditEnded event will not fired). How could I achieve the behavior when the cell loses focus, the GridView / RowDetails is updated?

I attached a solution that maps these issues.

Thanks a lot in advance.
Best regards
Nargis
Dimitrina
Telerik team
 answered on 15 Sep 2014
3 answers
245 views
On 9/5 I installed the latest "Telerik WPF VSExtensions" update (2014.3.820.0).  Sense then, it has not worked.  I've sent this to you many times (using the Wizard) but haven't heard back.  I need to know what to do here.  Do you have a previous version that I could roll back to?


Failed to handle solution references.System.NullReferenceException: Object reference not set to an instance of an object.
   at Telerik.VSX.SolutionManagement.SolutionDistribution.GetSourceDistributionAdditionalPaths()
   at Telerik.VSX.SolutionManagement.SolutionDistribution.get_SourceDistributionAdditionalPaths()
   at Telerik.VSX.SolutionManagement.SolutionReferenceManager.CheckIsReferenceFromAdditionalPath(String reference, SolutionDistribution distribution)
   at Telerik.VSX.SolutionManagement.SolutionReferenceManager.GetSolutionBasedReferences(IList`1 assemblyReferences, SolutionDistribution distribution)
   at Telerik.VSX.SolutionManagement.SolutionReferenceManager.CreateSolutionBasedReferences(IAssemblyWrap rootAssembly, IList`1 assemblyReferences, DistributionInfo distributionInfo, Guid projectGuid)
   at Telerik.VSX.Actions.UpdateReferencesAction.HandleSolutionReferences(IProjectWrapUIComponents projectWrap, IList`1& assemblyReferences)
   at Telerik.VSX.Actions.UpdateReferencesAction.UpdateReferences(IProjectWrapUIComponents projectWrap)
Ventsi
Telerik team
 answered on 14 Sep 2014
8 answers
456 views
I have several questions regarding copy paste within a RadSpreadsheetControl
1) I have a ViewModel that is set as the Datacontext of the usercontrol.  This VM controls many of the IsEnabled, IsVisible properties of the spreadsheet Control itself.  BUT in order to get the Context Menu and commands working, I have to reset the Datacontext of the radspreadsheet control to
                    DataContext="{Binding Path=CommandDescriptors, ElementName=radSpreadsheet}"  Is there a way to hook this all up w/o changing the DataContext of the RadSpreadsheetControl?

2) In order to get copy paste to work with <ctrl/shift>+Insert, I have to  Re-Register the inputBinding as such (Is this correct - it kinda works but may be the result of my other problem) - Why isn't this gesture automatically hooked up for the spreadsheet control like it is with the other editors within Telerik?
CommandManager.RegisterClassInputBinding(typeof(RadWorksheetEditor), new InputBinding(radSpreadBudgetSheet.CommandDescriptors.Copy.Command, new KeyGesture(Key.Insert, ModifierKeys.Control)));
CommandManager.RegisterClassInputBinding(typeof(RadWorksheetEditor), new InputBinding(radSpreadBudgetSheet.CommandDescriptors.Paste.Command, new KeyGesture(Key.Insert, ModifierKeys.Shift)));

3)  Since my radspreadsheet control contains data that I am storing in the database, I have hooked up the CellPropertyChanged event to monitor when things have changes and update my ViewModel.  But when the command is executed I am getting a range of MY ENTIRE SPREADSHEET in the CellPropertyChanged event.  This event is getting hammered because nearly every property is getting changed (protection, formatting, etc) when a cell is pasted.  Interestingly enough, if I go into a single cell, press F2 then "copy" (a cell value changed gets triggered here too!) then navigate to another cell press F2, then paste - I get a cell value changed for a single cell.  HOW CAN I get only the range of cells that was changed with the paste operation, not the entire spreadsheet!

Rod
Top achievements
Rank 1
 answered on 12 Sep 2014
4 answers
126 views
Hi All,

I am working on a module where RadTreeview will be sync up with Telerik Breadcrumb for a huge hierarchical data.
Tree and Breadcrumb are bind with different model and used dependency property ( context sharing ) for sync up between the controls.
Whenever user clicks on a tree node I'll set the breadcrumb's path with dummy child nodes since the data hierarchy is huge and to save service call for each breadcrumb items. Breadcrumb data will be populated whenever user clicks on the RadSplitButton or the  RadToggleButton associated with RadBreadcrumbBarItem. 

Currently I am not able to listen any events from RadSplitButton or RadToggleButton. 
Please help me if anybody implemented this. ( A sample will be really appreciated )


subash
Top achievements
Rank 1
 answered on 12 Sep 2014
3 answers
204 views
Sorry - This is supposed to posted  under TreeListView and not TreeView. I will try to repost under TreeListView.

I have a problem where after applying the Filter, it opens up all the nodes.

I am using CompositeFilterDescriptor.

We have a Huge Tree and we don't want the Tree and its children  to open after applying the Filter. Any idea how to stop it from opening after applying the Filter?

I am not able to attach the project, but will attach the screen shot. 

Here is code snippet. 

private void RadContextMenu_ItemClick(object sender, Telerik.Windows.RadRoutedEventArgs e)
        {
            if ((e.OriginalSource as RadMenuItem).Header.Equals("Show Spain"))
            {
                FilterDescriptor descriptor = new FilterDescriptor();
                descriptor.Member = "Country";
                descriptor.Operator = FilterOperator.IsEqualTo;
                descriptor.Value = "Spain";
                this.RadTreeListView1.FilterDescriptors.Add(descriptor);
            }
 
            CompositeFilterDescriptor mainFilter = new CompositeFilterDescriptor();
 
            if ((e.OriginalSource as RadMenuItem).Header.Equals("Show England"))
            {
                FilterDescriptor descriptor = new FilterDescriptor();
                descriptor.Member = "Country";
                descriptor.Operator = FilterOperator.IsEqualTo;
                descriptor.Value = "England";
                mainFilter.FilterDescriptors.Add(descriptor);
                this.RadTreeListView1.FilterDescriptors.Add(mainFilter);
            }
            if ((e.OriginalSource as RadMenuItem).Header.Equals("Show England - France"))
            {
                mainFilter = new CompositeFilterDescriptor();
                mainFilter.LogicalOperator = FilterCompositionLogicalOperator.Or;
                FilterDescriptor descriptor = new FilterDescriptor();
                descriptor.Member = "Country";
                descriptor.Operator = FilterOperator.IsEqualTo;
                descriptor.Value = "England";
 
                mainFilter.FilterDescriptors.Add(descriptor);
                descriptor = new FilterDescriptor();
                descriptor.Member = "Country";
                descriptor.Operator = FilterOperator.IsEqualTo;
                descriptor.Value = "France";
 
                mainFilter.FilterDescriptors.Add(descriptor);
 
                this.RadTreeListView1.FilterDescriptors.Add(mainFilter);
            }
 
            if ((e.OriginalSource as RadMenuItem).Header.Equals("Clear Filter"))
            {
                this.RadTreeListView1.FilterDescriptors.RemoveAt(0);
            }
             
        }
Dimitrina
Telerik team
 answered on 12 Sep 2014
1 answer
180 views
Hello -
We are about to start a new project that contains a grid with many, many columns. Although we have chosen Telerik for our grid control, we are trying to decide if it is best to create the columns in xaml, or in the code-behind. We have some questions that might help us decide between the xaml and code-behind options:

1. Performance - Is there any performance drain/gain for either option? Especially with large amounts of data?
2. Features - Ex...If a new column property is added in a new version, is it ever defaulted for one option, and not the other?
3. Maintainability - Is one option better supported than the other, especially in terms of upgrades?

Is there anything else we're not considering, or any issues that might sway us in one direction, versus another? Any information you can provide would be helpful.

Thanks!
Dimitrina
Telerik team
 answered on 12 Sep 2014
1 answer
98 views
Greetings!

Is it possible to add margins for container so the connections stops near or with some offset?
I've tried to:
 1) add margins to container template but then shapes that belong to container are being rendered without noticing that margin (attach 1)
 2) replace connectors for shape with increased offset from all sides but then connection looks pretty awful (attach 2)
I use OrgTreeRouter and every time something happens with container I call diagram layout with specific settings.
Is there any other way to get something like attach 3?
Martin Ivanov
Telerik team
 answered on 12 Sep 2014
Narrow your results
Selected tags
Tags
+? more
Top users last month
Rob
Top achievements
Rank 3
Iron
Iron
Iron
Atul
Top achievements
Rank 1
Iron
Iron
Iron
Alexander
Top achievements
Rank 1
Veteran
Iron
Serkan
Top achievements
Rank 1
Iron
Shawn
Top achievements
Rank 1
Iron
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Rob
Top achievements
Rank 3
Iron
Iron
Iron
Atul
Top achievements
Rank 1
Iron
Iron
Iron
Alexander
Top achievements
Rank 1
Veteran
Iron
Serkan
Top achievements
Rank 1
Iron
Shawn
Top achievements
Rank 1
Iron
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?