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

I attached an image showing what I like to have.

The idea - a chart representing values of a time series (line in the sample - could also be Bar or...).
During the period something happens (let's say it rains) - I know the start end the end time of this event.
Now I want to mark the rain period.

How can this be achived?

And I want the Y axes to be dynamic, so that if a higher value scrolls in it should expand, keeping the marked section to the top.

Last not least - it would be great if that will also work for Windows Phone and Windows 8.

Thank you
Manfred
ManniAT
Top achievements
Rank 2
 answered on 30 Jan 2014
2 answers
206 views
Hi,

I've got a RadGridView bound to an observable collection, I want to apply a DataTrigger style based on the IsAlternating value of the the row.
I've wired up the IsAlternating field to the grid (see xaml below) to see what value it is populating and it is always false.

 <telerik:GridViewDataColumn Header="Is Alternating"                                          
                                          DataMemberBinding="{Binding IsAlternating, RelativeSource={RelativeSource AncestorType={x:Type           telerik:GridViewRow}}}" Width="100"
                                                  HeaderTextAlignment="Center" TextAlignment="Center" />

So if I had 10 items in my collection, I would see 10 rows in my grid and the Is Alternating column display's false every time.
Am I misunderstanding what IsAlternating is used for?

I was under the impression that I would get something like (which is what I want)

Is Alternating
False
True
False
True
False
True
False
True
False
True

i.e. every other row would indicate if it is alternating or not.

Is there a  property that I can bind which will tell me if a row is alternating or not?

Thanks and regards,

Chris



Dimitrina
Telerik team
 answered on 30 Jan 2014
3 answers
198 views
Hi everyone,

I have developed a sample projet using RadControls for WPF Q3 2013 Trial Version.
The main window contains :
- A "Create Pane" button
- A user control which encapsulates a Docking control. The Docking's HasDocumentHost property is set to false

The StyleManager.ApplicationTheme property is set to an instance of SummerTheme.

Here is the user control's code-behind :

using System;
using System.Collections.Generic;
using System.IO;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
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 Telerik.Windows.Controls;
 
namespace NoDocumentHost
{
    /// <summary>
    /// Interaction logic for DockingUC.xaml
    /// </summary>
    public partial class DockingUC : UserControl
    {
        public DockingUC()
        {
            InitializeComponent();
        }
 
        public void CreatePane()
        {
            RadSplitContainer l_splitContainer = new RadSplitContainer();
            RadPaneGroup l_paneGroup = new RadPaneGroup();
 
            l_splitContainer.Items.Add(l_paneGroup);
            m_docking.Items.Add(l_splitContainer);
 
            RadPane l_pane = new RadPane()
            {
                CanUserPin = true,
                Title = "Title",
                Header = "Header",
                CanUserClose = true,
                ContextMenuTemplate = null
            };
 
            UserControl1 l_userControl = new UserControl1();
            l_pane.Content = l_userControl;
 
            l_paneGroup.Items.Add(l_pane);
            l_pane.MakeFloatingDockable();
        }
 
        private void DockingPaneStateChange(object p_sender, Telerik.Windows.RadRoutedEventArgs p_args)
        {
            Dispatcher.BeginInvoke(new Action(() =>
            {
                RadPane l_pane = (RadPane)p_args.OriginalSource;
                RadPaneGroup l_paneGroup = l_pane.PaneGroup;
                l_paneGroup.TabStripPlacement = Dock.Top;
            }));
        }
    }
}

A floating Pane is created when the user clicks the "Create button".
Each PaneGroup's TabStripPlacement property is set to Top.
The Pane header is not visible when a Pane is docked as shown on the attached picture 1.png.

I have commented the DockingPaneStateChange's body for a testing purpose.
Each PaneGroup's TabStripPlacement property was not set to Top.
The Pane header is visible when a Pane is docked as shown on the attached picture 2.png.

I have looked for information on how to make the Pane header visible when the PaneGroup's TabStripPlacement property is set to Top.
I have read the following forum thread : Forum Thread

I do not understand why the Pane header is not visible when the PaneGroup's TabStripPlacement property is set to Top.
Does the PaneGroup's TabStripPlacement property setter change the PaneGroup's TopTemplate property ?
Do I have to follow the procedure described on the forum thread ?

Thank you in advance for your answer
Vladi
Telerik team
 answered on 30 Jan 2014
5 answers
515 views
We are using the GridViewMaskedInputColumn in RadGridView with MaskType="Numeric".
The binded value is type of nullable integer, so is there any method to accept empty or a numeric value in the gridview column.

Update: it is supported by default, I have checked a different column.

But my question has a change, how to avoid default value 0 on cell edit.

Regards,
Reyas Mohammed
Reyas
Top achievements
Rank 2
 answered on 30 Jan 2014
5 answers
419 views
Hi,

Just I Updated my dlls ver from 2011 Q3 SP1 to 2012 Q2 SP1 (0730)
After this,

PlacementTarget of ContextMenu always returning null instead of actual element.

Is there any issue while getting PlacementTargetValue or is there any alternative for this?

I tried with GetClickedElement but it is not giving me exact element at most of the places.

For ex:,
I was added Context Menu to the parent element and I have some child elements to this parent element.
At this point of time, GetClickedElement is giving me the child element instead of parent element.
Rosen Vladimirov
Telerik team
 answered on 30 Jan 2014
1 answer
159 views
hi~
The issue can be showed in the code below
I have two TextBlocks, the only difference between them is where they are.
but the one inside the RadPane never fires a Drop Event.

xaml:
<Window x:Class="test.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="350" Width="525">
        <Grid>
        <Grid.ColumnDefinitions>
            <ColumnDefinition></ColumnDefinition>
            <ColumnDefinition></ColumnDefinition>
            <ColumnDefinition></ColumnDefinition>
        </Grid.ColumnDefinitions>
        <TextBlock Name="src" Text="src" Grid.Column="0" PreviewMouseDown="src_PreviewMouseDown"></TextBlock>
        <telerik:RadDocking Grid.Column="1">
            <telerik:RadSplitContainer HorizontalAlignment="Stretch">
            <telerik:RadPaneGroup>
                <telerik:RadPane>
                    <Grid>
                        <TextBlock AllowDrop="True" Background="LightYellow" Text="dst1" Drop="TextBlock_Drop"/>
                    </Grid>
                </telerik:RadPane>
            </telerik:RadPaneGroup>
            </telerik:RadSplitContainer>
        </telerik:RadDocking>
        <TextBlock AllowDrop="True" Background="LightBlue" Text="dst2" Drop="TextBlock_Drop" Grid.Column="2"/>
    </Grid>
</Window>

code behind:
//using blahblah...
namespace test
{
    public partial class MainWindow : Window
    {
        public MainWindow() {
            InitializeComponent();
        }
        private void TextBlock_Drop(object sender, DragEventArgs e) {
            (sender as TextBlock).Text = "On drop";
        }
        private void src_PreviewMouseDown(object sender, MouseButtonEventArgs e){
            string k = (sender as TextBlock).Text;
            DragDropEffects allowedEffects = DragDropEffects.Move | DragDropEffects.Copy | DragDropEffects.Link;
            DragDrop.DoDragDrop(sender as TextBlock, k, allowedEffects);
        }
    }
}
Rosen Vladimirov
Telerik team
 answered on 30 Jan 2014
3 answers
354 views
Hi,

I want to display dynamic data with a dynamic count of series.

There is already a, in my opinion, very straight forward solution for this in a RadChart (only difference is that I'm doing it with a StackedBarSeries, but it works as well).

[quote]Luis said:Hello,

I have a data structure like this:
Year - Team - Value
2010 - T1 - 50
2010 - T2 - 70
2009 - T1 - 40
2009 - T2 - 45
...

Years and teams can growing dinamically. I need a Bar Chart where:
- One data serie for each team
- Years in the axis X
- One bar for each serie in each year with the value as height

I've seen the "Data Binding with Automatic Series Mappings" sample, but it's not what i need.

Please, help me.
Thanks a lot.
[/quote]

<telerik:RadChart x:Name="RadChart1" >
    <telerik:RadChart.SeriesMappings>
        <telerik:SeriesMapping>
            <telerik:SeriesMapping.SeriesDefinition>
                <telerik:StackedBarSeriesDefinition />
            </telerik:SeriesMapping.SeriesDefinition>
            <telerik:SeriesMapping.GroupingSettings>
                <telerik:GroupingSettings ShouldCreateSeriesForLastGroup="True">
                    <telerik:GroupingSettings.GroupDescriptors>
                        <telerik:ChartGroupDescriptor Member="Team"/>
                    </telerik:GroupingSettings.GroupDescriptors>
                </telerik:GroupingSettings>
            </telerik:SeriesMapping.GroupingSettings>
            <telerik:SeriesMapping.ItemMappings>
                <telerik:ItemMapping FieldName="Value" DataPointMember="YValue" />
                <telerik:ItemMapping FieldName="Year" DataPointMember="XCategory" />
            </telerik:SeriesMapping.ItemMappings>
        </telerik:SeriesMapping>
    </telerik:RadChart.SeriesMappings>
</telerik:RadChart>

public partial class Example2 : UserControl
{
    public Example2()
    {
        InitializeComponent();
 
        List<Record> data = new List<Record>()
            {
                new Record(2009, "First team", 25),
                new Record(2010, "First team", 35),
                new Record(2011, "First team", 45),
                new Record(2009, "Second team", 15),
                new Record(2010, "Second team", 25),
                new Record(2011, "Second team", 75),
                new Record(2009, "Third team", 67),
                new Record(2010, "Third team", 20),
                new Record(2011, "Third team", 88),
                new Record(2009, "Fourth team", 34),
                new Record(2010, "Fourth team", 67),
                new Record(2011, "Fourth team", 91),
                new Record(2009, "Fifth team", 87),
                new Record(2010, "Fifth team", 77),
                new Record(2011, "Fifth team", 12)
            };
 
        this.RadChart1.ItemsSource = data;
    }
}
 
public class Record
{
    public Record(int year, string team, int value)
    {
        Year = year;
        Team = team;
        Value = value;
    }
 
    public int Value { get; set; }
    public string Team { get; set; }
    public int Year { get; set; }
}

Is it possible to do the same thing like in the link with a RadCartesianChart? Or should I stick with the RadChart?
Martin Ivanov
Telerik team
 answered on 29 Jan 2014
2 answers
324 views
Hi,

I'm using the version Q3 2013 SP1 (2013.3.1204.40).
Is it possible to make the watermark text, e.g. "Type a name" in the attached picture, right alignment?
Thanks.

Regards,
Gong
Vadimir
Top achievements
Rank 1
 answered on 29 Jan 2014
1 answer
124 views
Hi,

    I am working on a Xbap application with the PersistenceFramwork (the latest version of WPF controls). It all work fine when I have only single xbap page, but if i have multiple pages in same application, it fails.

    After I assigned different page to the "Mainwindow.Content" and try to find those settings that I stored in previous page, it always return 0. But if I go back to previous page, I do get those settings.

    How can I retrieve those settings in different pages?

Code that I used:

  Dim m_isoStorageProvider As New Telerik.Windows.Persistence.Storage.IsolatedStorageProvider()
        Dim arrStorageFiles As New List(Of String)
        arrStorageFiles.Add("GridView1")
        arrStorageFiles.Add("GridView2")
        m_isoStorageProvider.LoadFromStorage(arrStorageFiles.ToArray)


Thanks
Chris

Zarko
Telerik team
 answered on 29 Jan 2014
1 answer
69 views
I have a DataForm with various DataFormComboboxFields. I'm using autogeneration to populate the DataForm.

How can I change the appearance of RadComboBoxes in the DataFormComboBoxFields at runtime?

I want to be able to show or hide the SelectionButton that appears inside the ComboBoxes (Property ClearSelectionButtonVisibility  of RadComboBox). Some DataFormComboBoxFields should show this button, others not...

 
Yoan
Telerik team
 answered on 29 Jan 2014
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
ProgressBar
Sparkline
LayoutControl
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
Rating
SplashScreen
Accessibility
Callout
CollectionNavigator
Localization
AutoSuggestBox
Security
VirtualKeyboard
HighlightTextBlock
TouchManager
StepProgressBar
Badge
OfficeNavigationBar
ExpressionParser
CircularProgressBar
SvgImage
PipsPager
SlideView
AI Coding Assistant
+? more
Top users last month
Top achievements
Rank 1
Iron
Iron
Iron
Rob
Top achievements
Rank 3
Bronze
Bronze
Iron
ivory
Top achievements
Rank 1
Iron
Nurik
Top achievements
Rank 2
Iron
Iron
YF
Top achievements
Rank 1
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Top achievements
Rank 1
Iron
Iron
Iron
Rob
Top achievements
Rank 3
Bronze
Bronze
Iron
ivory
Top achievements
Rank 1
Iron
Nurik
Top achievements
Rank 2
Iron
Iron
YF
Top achievements
Rank 1
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?