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

Is there a file upload/download control in wpf suite? (something like a textbox with spinner to represent upload/download. And a cancel button to cancel upload/download)

Thanks
Santosh
Tina Stancheva
Telerik team
 answered on 28 Sep 2012
1 answer
79 views
Do you have an example of using Virtualization with the WPF PropertyGrid?
Maya
Telerik team
 answered on 28 Sep 2012
1 answer
185 views
hello all, I use the follwing code to create a radsplitcontainer dynamically and it works perfectly fine.

However when I try to add a pane group (commeneted code) I couldn't even see the split container showing to the right side of the window

Any suggestions, please?

Telerik.Windows.Controls.RadSplitContainer RightSplit =

 

new Telerik.Windows.Controls.RadSplitContainer();

RightSplit.InitialPosition = Telerik.Windows.Controls.Docking.DockState.DockedRight;

RightSplit.BorderBrush = Brushes.DarkSlateGray;

RightSplit.BorderThickness =

 

new System.Windows.Thickness(3);

RightSplit.Width =

 

100;

RightSplit.IsEnabled =

 

true;

RightSplit.Visibility = Visibility.Visible;

MainContainer.Items.Add(RightSplit);

 

//Telerik.Windows.Controls.RadPaneGroup thispaneGroup = new Telerik.Windows.Controls.RadPaneGroup();

 

//thispaneGroup.Width = 100;

 

//RightSplit.Items.Add(thispaneGroup);


Regards
RK
Georgi
Telerik team
 answered on 28 Sep 2012
1 answer
131 views
I have been looking around for how to do a pie chart with a hollow middle (see the attachment), but have come up empty so far after searching for information on RadPieChart and PieSeries in particular, and for creating my own Path or Style in general. What would be the strategy to do this kind of pie chart?

I am building the PieSeries in C# code and not in XAML, so C# would be greatly appreciated. Thanks.
Vladimir Milev
Telerik team
 answered on 28 Sep 2012
0 answers
215 views
Hi there,

I am currently having troubles with RoutedEvent in WPF. I made a simple example only using native WPF components. The example is made of a button executing a long term synchronous task the first time it's hit and showing a message "Already executed" all other times.

What you have to do to reproduce my issue is to click the button once, and when the task is executing click a second time => After finishing the first task the second click event is going to trigger a second execution => "Already executed". I want to consume any user input during the execution before it triggers an event.

How could I do that ?

<Window x:Class="TestDBConnection.MainWindow"
        Title="MainWindow" Height="350" Width="525">
    <Grid>
         
        <Button Name="butt" Height="30" Width="150" />
        <Label Visibility="Collapsed" Name="label">Executing ... </Label>
    </Grid>
</Window>
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Data;
using System.Windows.Documents;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Imaging;
using System.Windows.Navigation;
using System.Windows.Shapes;
using System.Data.Objects;
 
namespace TestDBConnection
{
    /// <summary>
    /// Logique d'interaction pour MainWindow.xaml
    /// </summary>
    public partial class MainWindow : Window
    {
        public MainWindow()
        {
            InitializeComponent();
 
            var cmd = new MyCommand();
            //butt.Command = cmd;
 
            //butt.PreviewMouseDown += new MouseButtonEventHandler(butt_PreviewMouseDown);
            butt.Click += butt_Click;
 
            cmd.label = label;
            cmd.bouton = butt;
 
        }
 
        void butt_PreviewMouseDown(object sender, MouseButtonEventArgs e)
        {
            //label.Visibility = Visibility.Visible;
        }
 
        void butt_Click(object sender, RoutedEventArgs e)
        {
            if (executedAlready)
            {
                MessageBox.Show("Already Executed");
                return;
            }
 
            for (long i = 0; i < 40000; i++)
            {
                for (long j = 0; j < 40000; j++)
                {
                    var a = i + j;
                }
            }
 
            //label.Visibility = Visibility.Collapsed;
            executedAlready = true;
        }
 
        private bool executedAlready;
    }
 
    public class MyCommand : ICommand
    {
 
        public bool CanExecute(object parameter)
        {
            return true;
        }
 
        public event EventHandler CanExecuteChanged;
 
        public void Execute(object parameter)
        {
            if (executedAlready)
            {
                MessageBox.Show("Already Executed");
                return;
            }
 
            for (long i = 0; i < 40000; i++)
            {
                for (long j = 0; j < 40000; j++)
                {
                    var a = i + j;
                }
            }
 
            executedAlready = true;
 
            label.Visibility = Visibility.Collapsed;
        }
 
        public Label label;
        public Button bouton;
        public Window window;
 
        private bool executedAlready;
    }
}
Joël
Top achievements
Rank 2
 asked on 28 Sep 2012
1 answer
553 views
I have been searching for a while now and have not come up with solution to a feature I need to implement.

I have set the background color for multiple columns in my RadGridView to be bound to a user's selection. For example, if they select option 1, the first column will be highlighted. If they select option 2, the second column is highlighted, and the highlight from the first column is removed. I currently have the style for the column set up as follows:

<telerik:GridViewColumn.Style>
    <Style BasedOn="{StaticResource CommonColumnStyle}" TargetType="{x:Type telerik:GridViewColumn}">
        <Style.Triggers>
            <DataTrigger Value="True">
                <DataTrigger.Binding>
                    <MultiBinding Converter="{StaticResource ColumnIsSelectedConverter}" ConverterParameter="0">
                        <Binding ElementName="LayoutRoot" Path="DataContext.AllowedOptions" />
                        <Binding ElementName="LayoutRoot" Path="DataContext.SelectedOptions" />
                    </MultiBinding>
                </DataTrigger.Binding>
                <Setter Property="Background" Value="{DynamicResource ColumnHighlightColor}" />
            </DataTrigger>
        </Style.Triggers>
    </Style>
</telerik:GridViewColumn.Style>

The CommonColumnStyle just defines text alignment, trimming, and a default background of transparent. The ColumnIsSelectedConverter returns true or false. The ViewModel contains an IList of options that are displayed to the user in the order that they also appear in the grid. This lets me use the ConverterParameter to specify that this is the nth column in the XAML.

There are two problems with this implementation:

  1. I'm also defining footers for these columns. The first column's data cells and footer start with the ColumnHighlightColor. If the user changes the selected option, the data cell backgrounds update, but the footer background does not change. (e.g. first column returns to transparent, second column is now highlighted, but the first column's footer is still highlighted and the second footer is transparent.) I was able to get around this by defining a style/triggers for the footer cells as well, but I don't think that should be necessary. I'm curious if this is by design or a bug.

  2. The column background only appears for rows with data and in the footer row, not the unoccupied rows. We have our GridView set to fill up most of the screen, so we would like the column background to show up from the top of the GridView to the bottom. Is there a way around this?

Thanks!
Maya
Telerik team
 answered on 28 Sep 2012
1 answer
195 views
Is there any way that I can do that?
Petar Kirov
Telerik team
 answered on 27 Sep 2012
1 answer
166 views
We have a RadGridView with a Hierarchical RadGridView in a template.
We bind the selected item of the Hierarchical grid to an object in our ViewModel. (with PropertyChanged...).

When we change the object in our ViewModel, the expected row in de Hierarchical grid is not selected.

Is there a way to select an item in a Hierarchical grid from codebehind?.

Dimitrina
Telerik team
 answered on 27 Sep 2012
1 answer
167 views
I'm working on a project about Persian spell checker in the C# language. I have googled it and found some alternatives, but non of them draw "Wavy line" under misspelled words. for example I try to use Telerik RadRichTextBox and set my Application's Culture to "fa-IR" then load Persian Dictionary but It draw "Wavy Line" under any word (even correct English words) Except Persian Word. So I want to know, How can I draw wavy line under a certain word?
Vasil
Telerik team
 answered on 27 Sep 2012
3 answers
145 views
Hi,

We are getting errors related to DataQueryService class when we construct a QueryableDataServiceCollectionView instance from a WCFDataServices 5.0 DataServicesContext and DataServiceQuery.The application is complaining about the WCF DataService 4.0 assembly (System.Data.Services.Client.dll) !!!

The errors occurred after we ported the application from (WPF4.0 + WCFDataServices 4.0 + EF4.3) to (WPF4.5 + WCFDataServices 5.0 + EF5.0).

I saw an earlier reply from Telerik team that QueryableDataServiceCollectionView is not supported with WCF Data Services October 2011 CTP.Does this also apply to WCF DataServices 5.0 which is an offical version ??.



Environment:

VS 2012 Ultimate
NET 4.5
EF 5.0
WCF Data Services 5.0
WPF 4.5
Telerik WPF 2012.2 912

Thanks in advance

Madani


Rossen Hristov
Telerik team
 answered on 27 Sep 2012
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?