Telerik Forums
UI for WPF Forum
1 answer
45 views
Hi

I am trying to do an upgrade to the latest version of WPF telerik and here are some of the methods that I cannot find in q2 2014.

Can you please tell me with which methods I can substitute the following methods with in the latest version?

Telerik.Windows.Controls.GanttView.GanttViewGridSplitter.GanttViewGridSplitter()
Telerik.Windows.Controls.GanttView.GanttDragVisualCue.GanttDragVisualCue()
Telerik.Windows.Controls.GanttView.CellSelectionContainer.CellSelectionContainer()

Telerik.Windows.Rendering.SchedulingScrollContentPresenter.SchedulingScrollContentPresenter()



Thanks
Marius
Polya
Telerik team
 answered on 27 Jun 2014
4 answers
209 views
I have a usual UserControl with a button. I just want so show a RadWindow.Alert. Here's the Code behind:

public partial class TestView
{
    public TestView()
    {
        InitializeComponent();
    }
 
    private void TestButton_OnClick(object sender, RoutedEventArgs e)
    {
        RadWindow.Alert(new DialogParameters
            {
                Content = "Test",
                ContentStyle = Resources["RadAlertStyle"] as Style,
                WindowStyle = Resources["RadWindowStyle"] as Style
            });
    }
}


This is done as shown in the WPF demos but in my case the buttons on the RadWindow.Alert dialog are not styled. I use Telerik Windows 8 theme. All RadButtons are style correctly in Windows 8 style but not on any of my RadWindow dialogs. What am I missing? Please see attached image.


Kalin
Telerik team
 answered on 27 Jun 2014
2 answers
117 views

Hi,

I noticed some strange behaviour when using implicit styles and the using a custom style for a row in the gridivew... has anyone seen anything like this before..

... I have used this custom style before with success (as stated in the links below) ,... untill I start using implicit style (visual studio 2013)

http://www.telerik.com/forums/maxrowheight
http://www.telerik.com/forums/change-row-height


I made a sample project. If I remove the following piece of code from the gridview, everything works fine:

RowStyle="{StaticResource CustomRowStyle}"

If you want to check, you can download the sample project here:

https://drive.google.com/file/d/0B_OMCdXJPjZuVHg0WVczYWhiejg/edit?usp=sharing  (click File => Download)

Thanks !



Erdem
Top achievements
Rank 1
 answered on 27 Jun 2014
4 answers
471 views
Sorry for the naive question...

I am a first time user of the telerik WPF controls, I am following the tutorial here to add a RadGridView to my application...

My wpf application is build using MVVM, I am adding the RadGridView control to one of the views, see implementation below...

<UserControl x:Class="SprintAnalyzer.Module.Presentation.Views.MiddleView"
             xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
             xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
             xmlns:telerik="http://schemas.telerik.com/2008/xaml/presentation"
            xmlns:prism="clr-namespace:Microsoft.Practices.Prism.Interactivity.InteractionRequest;assembly=Microsoft.Practices.Prism.Interactivity"
            xmlns:i="clr-namespace:System.Windows.Interactivity;assembly=System.Windows.Interactivity"
             xmlns:interactions="clr-namespace:SprintAnalyzer.Module.Presentation.Interactions"
             xmlns:Views="clr-namespace:SprintAnalyzer.Module.Presentation.Views" mc:Ignorable="d"            
             d:DesignHeight="300" d:DesignWidth="300">
 
    <Grid x:Name="LayoutRoot" Background="Lavender">
        <telerik:RadGridView x:Name="radGridView" AutoGenerateColumns="True"
                             ItemsSource="{Binding Path=AnalysisResults}" >
            <telerik:RadGridView.Columns>
                <telerik:GridViewDataColumn DataMemberBinding="{Binding Result}" Header="Result"/>
                <telerik:GridViewDataColumn DataMemberBinding="{Binding Category}" Header="Category"/>
            </telerik:RadGridView.Columns>
        </telerik:RadGridView>
    </Grid>
</UserControl>

Note - I have added a reference to xmlns:telerik="http://schemas.telerik.com/2008/xaml/presentation" my project already has a reference to the Telerik.Windows.Code, Telerik.Windows.Controls.GridView and Telerik.Windows.Controls.Input. 

When I run the application, the grid is not displayed at all. 

The viewmodel implementation,

using System;
using System.Collections.Generic;
using System.Collections.ObjectModel;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Input;
using Microsoft.Practices.Prism.Commands;
using Microsoft.Practices.Prism.Events;
using SprintAnalyzer.Common;
using SprintAnalyzer.Common.Service;
using SprintAnalyzer.Module.Presentation.Models;
using SprintAnalyzer.Module.Presentation.Requests;
using SprintAnalyzer.RulesEngine;
using SprintAnalyzer.Common.Events;
 
namespace SprintAnalyzer.Module.Presentation.ViewModels
{
    public class MiddleViewModel : ViewModelBase
    {
        private readonly IEventAggregator _eventAggregator;
        private ICommand _button;     
        public string Output { get; private set; }
 
        public ICommand OnClick
        {
            get { return _button; }
            set
            {
                _button = value;
                RaisePropertyChangedEvent("OnClick");
            }
        }
 
        public MiddleViewModel(IApplicationContextService contextService, IEventAggregator eventAggregator)
        {
            this._contextService = contextService;
            this._eventAggregator = eventAggregator;
            this.OnClick = new DelegateCommand(this.Button_Clicked);
            _eventAggregator.GetEvent<AnalysisRunTrigger>().Subscribe(ExecuteAnalysisRunTrigger, ThreadOption.BackgroundThread);
            _eventAggregator.GetEvent<AnalysisResultEvent>().Subscribe(OnAnalysisRunResult, ThreadOption.UIThread);
            _eventAggregator.GetEvent<ExceptionRaisedEvent>().Subscribe(OnExceptionRaised,
                                                                       ThreadOption.UIThread);
            this.AnalysisResults = new ObservableCollection<AnalysisResult>();
        }
 
        private void OnExceptionRaised(ExceptionDetail obj)
        {
               // Removed for now
        }
 
        private void OnAnalysisRunResult(AnalysisResult analysisResult)
        {
            AnalysisResults.Add(analysisResult);
        }
 
        private static Person CreatePerson()
        {
               // Removed for now
        }
 
        private void SetPeopleExecute()
        {
                // Removed for now
        }
 
        private void GetPersonCallback(Person p)
        {
              // Removed for now
        }
 
        private void CancelCallback()
        {
             // Removed for now
        }
 
        private ObservableCollection<AnalysisResult> _analysisResults;
        public ObservableCollection<AnalysisResult> AnalysisResults
        {
            get
            {
                return _analysisResults;
            }
            set
            {
                _analysisResults = value;
                RaisePropertyChangedEvent("AnalysisResults");
            }
        }
 
        private void ExecuteAnalysisRunTrigger(string triggerState)
        {
            try
            {
                switch (triggerState)
                {
                    case "StartAnalyzis":
                        
                        rulesFactory.Execute();
 
                        break;
                }
            }
            catch (Exception ex)
            {
                _eventAggregator.GetEvent<ExceptionRaisedEvent>().Publish(new ExceptionDetail() { Message = ex.Message });
            }
        }
 
        private string _message;
        private readonly IApplicationContextService _contextService;
 
        public string Message
        {
            get { return _message; }
            set
            {
                _message = value;
                RaisePropertyChangedEvent("Message");
            }
        }
 
        private void Button_Clicked()
        {
            //throw new NotImplementedException();
        }
    }
}


Note that the AnalysisResults is ObservableCollection...

If I take the RadGridView out of the equation and use the good old Wpf GridView control, my application works, I can see the grid load up with the values for the same code...

What am I missing?
 
 
Dimitrina
Telerik team
 answered on 27 Jun 2014
9 answers
294 views
I am working on a Diagram application that allows shapes to be dragged on to the Diagram from a side panel. Also available in the side panel are objects representing different kinds of Connections that could potentially exist between shapes in the Diagram. The functionality I am attempting to create is as follows:

- Two or more shapes exist in the diagram
- User clicks on one of the Connection types available in the side panel and drags it onto one of the shapes in the diagram

I've come this far and have appropriate event handlers set up to manipulate the relevant view models. Here is where I'm having trouble though.

- When the drag drop of a connection onto a shape is complete and the user lets go of the mouse, I would like to "attach" the RadDiagramConnection to their mouse cursor so that they can freely move it around on the diagram. Clicking on another shape on the diagram should set the RadDiagramConnection's target to the selected shape so that a connection is created between the two. 

I've been through all the examples in the DragDropManager and Diagram controls and haven't seen anything that looks similar to this kind of functionality, so I'm hoping that somewhere out there someone has done something like this before. Would appreciate any suggestions!
Martin Ivanov
Telerik team
 answered on 27 Jun 2014
1 answer
268 views
Hi,
I am new to MVVM. I am trying to implement my a custom server side sorting with MVVM. I am able to handle the sorting command, where I asynchronously read data from the Web API. In the call back, I update the list which is bound to the grid's Itemsource. But this is clearing the sort arrow on the column header. Can some one give me a sample with this sort of Custom Sorting implemented and still able to retain the sort arrows on the column header.
Nick
Telerik team
 answered on 27 Jun 2014
2 answers
196 views
Is there anyway to customize a DragPreview in WPF when using Telerik RadTreeView?

I've set  
IsDragPreviewEnabled="True"
but all that does is display the namespace in a button rather than a preview of the actual item being dragged (which in this case is a row of a grid)

Idon't necessarily need show a preview of the row I'm dragging - it would be good enough to show a standard image, just to give the user some feedback that the drag was taking place.</p>

Any ideas how I could achieve this?

Thanks
Evgenia
Telerik team
 answered on 27 Jun 2014
7 answers
412 views
Hi,

I need to iterate all rows in the grid under for the following criteria:

Virtual Rows and Columns are enabled 
I am using GridView filter capabilities to reduce number of visible rows

I know from reading similar forum responses that it is strongly recommended not to iterate the grid rows but iterate thru the bound data object.  However, the data object does not reflect the filtering on the data as displayed in the grid.   In my app I need to save the data (no filtered rows) in a custom format to a file.  How do you recommend I do this?

Since the GridView software is aware of virtual rows and is also aware of what is filtered a new GridView method to iterate the data object would be very helpful.  This method would take into account the filtering as well as columns hidded by a column chooser.

Thanks
Rich

Matt
Top achievements
Rank 1
 answered on 26 Jun 2014
2 answers
342 views
Hello,

I search a way to add an image in Excel Export.

In SpreadSheet overview (http://www.telerik.com/help/wpf/radspreadsheet-overview.html) i can see "Supported feature : Images" ... Good !

I found this on your documentation : http://www.telerik.com/help/wpf/radspreadsheet-model-features-shapes-and-images.html
Sems I can create a "Floating Image" an add it to the shapes of WorkSheet : well !

BUT in my code, I don't have the Shapes collection on WorkSheet !

Telerik.Windows.Documents.Spreadsheet.Model.Worksheet sheet; sheet.Shapes ?
Telerik.Windows.Controls.RadSpreadsheet r; r.ActiveWorksheet.Shapes ?

Can't find FloatingImage anyway ?

I use Telerik 2013 Q3

Who to add my image ?
Thx
JC
Top achievements
Rank 1
 answered on 26 Jun 2014
1 answer
111 views
Hello, i'm using trial version of DevCraft (Q1 2014). And we're very interested in purchasing full version soon.

But i've got some bad performance experience when we are using ru-RU tdf Dictionary. I think that's because of its size (14Mb). 

The main problem is with context menu with suggestions. When i make right-click on underlined by spellchecker word, i have to wait up to 10 seconds before context menu with suggestions is shown. Same experience i have with spelling dialog.

Are there any performace tips&tricks for my case?

There is no problem with English Dictionary and Spanish one.



Boby
Telerik team
 answered on 26 Jun 2014
Narrow your results
Selected tags
Tags
+? more
Top users last month
Jay
Top achievements
Rank 3
Iron
Iron
Iron
Benjamin
Top achievements
Rank 3
Bronze
Iron
Veteran
Radek
Top achievements
Rank 2
Iron
Iron
Iron
Bohdan
Top achievements
Rank 2
Iron
Iron
Richard
Top achievements
Rank 4
Bronze
Bronze
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Jay
Top achievements
Rank 3
Iron
Iron
Iron
Benjamin
Top achievements
Rank 3
Bronze
Iron
Veteran
Radek
Top achievements
Rank 2
Iron
Iron
Iron
Bohdan
Top achievements
Rank 2
Iron
Iron
Richard
Top achievements
Rank 4
Bronze
Bronze
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?