Telerik Forums
UI for WPF Forum
0 answers
99 views

Hi. I am using RadComboBox control in my project. Previously, the control was in non-editable mode (IsEditable="False") and drop functions worked fine.

<telerik:RadComboBox
IsEditable="True"
IsFilteringEnabled="True"
AllowDrop="True"
ItemsSource="{Binding Type.Items}"
DisplayMemberPath="DocumentId"
Text="{Binding Value, Mode=TwoWay}">
<i:Interaction.Behaviors>
<local:DropTargetBehavior DropCommand="{Binding DropCommand}" />
</i:Interaction.Behaviors>
</telerik:RadComboBox

 

When I set IsEditable to True then drop functionality has stopped working. In editable mode there is an "Input Area" overlay control and i cannot drop anything to RadComboBox. Can you suggest any working example for dropping something to RadComboBox in editable mode (IsEditable="True")?

Vladimir
Top achievements
Rank 1
 asked on 08 Nov 2018
1 answer
175 views
When I press Filter button in any RadGridView's column and then press Alt+Tab to switch to other window, filter popup stays on top.
Dinko | Tech Support Engineer
Telerik team
 answered on 07 Nov 2018
2 answers
186 views

When I switched to Fluent theme all RadRibbonButtons direct content was aligned to the left instead of centered as it was previously in Expression Dark theme. The problem is, that ContentPresenter in StackPanel named FirstRowContainer has its HorizontalAlignment property set to Left. I don't know how can I change that to Center and I need your help to fix it. Direct content of buttons is TextBlock displaying Font Glyph. Here is sample code:

                        <telerik:RadRibbonButton x:Name="buttonLock"
                                                 Click="ButtonLock_OnClick"
                                                 IsEnabled="{Binding IsUiUnlocked}"
                                                 Size="Large"
                                                 Text="Lock">
                            <TextBlock Margin="2"
                                       FontFamily="{StaticResource TelerikWebUI}"
                                       FontSize="24"
                                       Foreground="#00BFE8"
                                       Text="{StaticResource GlyphLock}" />
                        </telerik:RadRibbonButton>

Jan
Top achievements
Rank 1
 answered on 07 Nov 2018
3 answers
123 views

Hi,

I would like to create two generic custom aggregators as like your CounterFunction class with the following differences

1st aggregator: it should count only not null value and not the empty strings

2nd aggreagator: it should count the distinct values (example: a a a b b c -> count =3 )

 

Any idea?

Thank you

Vladimir Stoyanov
Telerik team
 answered on 07 Nov 2018
2 answers
246 views

Hi!

For example I took an DockingIntegration_WPF project from examples provided by Telerik. I set up grid snapping and it has worked fine, until I have rotated the shape on 90 (or 270) degrees.
After rotation, the shape does not snap to grid  neither when I drag it over the diagram nor I drop it on the diagram.
But when I rotate the shape on 180 degrees , it snaps to grid well.
On attached picture you can see this bug.
Is it possible to fix this issue?

toschkin
Top achievements
Rank 1
 answered on 06 Nov 2018
0 answers
44 views

I have VerticalLinearScale with properties:

Min= 0

Max = 100

MajorTickStep = 20

MiddleTicks = 4

by click on button I changed the values of the properties to:

Min= 0
Max = 30000
MajorTickStep = 5000
MiddleTicks = 10

the problem is that it takes too much time till the element render again with the new values

I attached my sample with the problem

Thanks,

Shoshana

 

 

שושי
Top achievements
Rank 1
 asked on 06 Nov 2018
3 answers
60 views

Hello again!

I am creating custom RadDiagramShape as it is written in Telerik documentation: https://docs.telerik.com/devtools/wpf/controls/raddiagram/howto/create-custom-shape . It contains 2 borders and an image inside of them. When I am doing it according to the documentation, rotation and zoom after rotation works weird with ancor-points of this CustomControl. When I am doing 2 borders and an image inside RadDiagramShape inside xaml without any CustomControl it works as it should.

The picture of weird behaviour is attached (after rotating of both figures).

Would you be so kind to tell me how I can fix this weird behaviour of my CustomControl?

This is my .cs code

public class RasterObject : RadDiagramShapeBase
{
    static RasterObject()
    {
        DefaultStyleKeyProperty.OverrideMetadata(typeof(RasterObject), new FrameworkPropertyMetadata(typeof(RasterObject)));
    }
 
    public static readonly DependencyProperty ContrastyBorderBrushProperty =
         DependencyProperty.Register("ContrastyBorderBrush", typeof(Brush),
         typeof(RasterObject), new FrameworkPropertyMetadata(Brushes.Transparent));
 
    // .NET Property wrapper
    public Brush ContrastyBorderBrush
    {
        get { return (Brush)GetValue(ContrastyBorderBrushProperty); }
        set { SetValue(ContrastyBorderBrushProperty, value); }
    }
 
    public static readonly DependencyProperty SourceProperty =
         DependencyProperty.Register("Source", typeof(ImageSource),
         typeof(RasterObject));
 
    // .NET Property wrapper
    public ImageSource Source
    {
        get { return (ImageSource)GetValue(SourceProperty); }
        set { SetValue(SourceProperty, value); }
    }
 
 
}

This is my style code:

<Style TargetType="{x:Type local:RasterObject}">
    <Setter Property="Template">
        <Setter.Value>
            <ControlTemplate TargetType="{x:Type local:RasterObject}">
                <Border BorderBrush="{TemplateBinding ContrastyBorderBrush}"
                        BorderThickness="{TemplateBinding BorderThickness}">
                    <Border Background="{TemplateBinding Background}"
                            BorderBrush="{TemplateBinding BorderBrush}"
                            BorderThickness="{TemplateBinding BorderThickness}">
                        <Image Source="{TemplateBinding Source}" Stretch="Fill"/>
                    </Border>
                </Border>
            </ControlTemplate>
        </Setter.Value>
    </Setter>
</Style>

This is my Xaml code:

<telerik:RadDiagram  IsBackgroundSurfaceVisible="True">
                                     
                                    <telerik:RadDiagramShape Position="50, 50" Background="Transparent" BorderBrush="Transparent">
                                        <Border BorderBrush="Red" BorderThickness="13" >
                                            <Border BorderBrush="Blue" BorderThickness="23" >
                                                <Image Source="/Images/MainToolbar/Arc.png" Stretch="Fill"/>
                                            </Border>
                                        </Border>
                                    </telerik:RadDiagramShape>
                                    <imageeditor:RasterObject BorderBrush="Gray" BorderThickness="10"
                                                               ContrastyBorderBrush="White"
                                                              Source="/Images/MainToolbar/Arc.png"/>
                                     
 
                                </telerik:RadDiagram>

 

Best regards,
Tatiana

Martin Ivanov
Telerik team
 answered on 06 Nov 2018
11 answers
317 views
Hello, I'm just wondering if this is possible out of the box through a setting. We want the user to be able to press Esc while dragging an object and have that cancel the dragging, just like in the Windows Explorer.

Thanks.
Dinko | Tech Support Engineer
Telerik team
 answered on 05 Nov 2018
8 answers
203 views

     I downloaded the WPF demo app to get examples on how to create UI items similar to the examples.  I'm finding that I'm always missing references and have to google which reference I need for certain controls.  I also can't find resources, not sure if they are in another library or if they were omitted from the source code.  It's getting frustrating to struggle with every control.

Right now I'm trying to get the RadPieChart to work so I copied in the markup into my page and the RadPieChart wasn't found.  I had to google to find out I was missing a reference to Telerik.Windows.Controls.Chart. 

Now I got that working but noticed I was missing some styles which I found in the Resources.xaml.  When I copy in those styles they have "basedon" set to another style and I don't know if it's missing or if it's a reference.

Any chance these demos could be easier to copy in so I don't have to google everything and figure it out, I don't need anything fancy, I just need it to work so I can start fiddling around with it.

For reference I'm looking at the Layout Control and trying to get a little doughnut pie chart like in the steps per day.

Martin Ivanov
Telerik team
 answered on 05 Nov 2018
1 answer
566 views

I have a very simple wizard that contains 3 pages. The first page should always be shown and is the starting point for the wizard. Now, I have the SelectionChanging event hooked up on the wizard to perform some validation before allowing the user to move on. However, here is where the trick comes in:I would like to be able to skip step two if certain conditions are met and move the user directly to the last page of the wizard. Likewise, as long as this condition is met, if the user then clicks Back to go to the previous step, I'd like to take the user to the first page in this scenario.

I cannot remove the second page of the wizard because this page may be needed in some cases depending on whether the specified criteria is met. Apparently, setting the Wizard's SelectedPage property to the page I want isn't the right way to do it because it puts the wizard into an infinite loop where it keeps going between the first page and the last page because when I set the SelectedPage to the last page, the SelectionChanging event is raised again, but this time with the direction saying Backward which gets the wizard to go back to the first page since the OldPage is now the last page and the direction is Backward and the criteria for skipping the middle step is met, the SelectedPage is set back to the first page which raises the SelectionChanging event with the direction Forward and the OldPage being the first page... and round and round we go.

I'm looking for a solution that doesn't require me to add or remove pages to the collection on the fly and doesn't briefly navigate to the second page in a fashion that it creates a "stutter" to the user where it's obvious that the software is simulating the user clicking the next button when the second page is active.

 

TIA.

Martin Ivanov
Telerik team
 answered on 05 Nov 2018
Narrow your results
Selected tags
Tags
+? more
Top users last month
Will
Top achievements
Rank 2
Iron
Motti
Top achievements
Rank 1
Iron
Hester
Top achievements
Rank 1
Iron
Bob
Top achievements
Rank 3
Iron
Iron
Veteran
Thomas
Top achievements
Rank 2
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Will
Top achievements
Rank 2
Iron
Motti
Top achievements
Rank 1
Iron
Hester
Top achievements
Rank 1
Iron
Bob
Top achievements
Rank 3
Iron
Iron
Veteran
Thomas
Top achievements
Rank 2
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?