Telerik Forums
UI for WPF Forum
1 answer
88 views
Hi,
I need to use a WPF TimeBar control within a legacy winforms application (as there isnt one in the winforms suite).
Is it possible to simply host your WPF TimeBar control inside an ElementHost on a winforms form ?
If so, would there be any limitations or things that may not work as anticipated ?

Thanks,
S.
Evgenia
Telerik team
 answered on 29 Mar 2012
3 answers
189 views
Hi,

I had found an issue with WPF TimePicker control for .Net 4.0.
When I type in 130 in the time field, it gets converted to 1PM. Its coz it considers it as 13 and 0.So it becomes 1:00PM instead of 1:30AM.
Similary 230 converts to 11PM, thinking its 23:00hrs.
This issue works fine in ASP.Net control (ie:130 gets converted to 1:30AM). I had tried with the demo version of the latest release.

Is this a bug?

Thanks
Konstantina
Telerik team
 answered on 29 Mar 2012
1 answer
264 views
I just download telerik for WPF.

I use ChartView and i would like to bind String on Horizontal Axis and sort it on an other binding.

Is it possible ?

            <chart:RadCartesianChart Name="BarChart" Palette="Metro" VerticalAlignment="Stretch" HorizontalAlignment="Stretch" >
                <chart:RadCartesianChart.HorizontalAxis>
                    <chartView:CategoricalAxis Title="HorizontalAxis" LabelFitMode="MultiLine" LabelStyle="{StaticResource AxisLabelStyle}" >
                        <chartView:CategoricalAxis.TitleTemplate>
                            <DataTemplate>
                                <TextBlock Text="{Binding StepPosition}" Margin="0,6,0,10" Style="{StaticResource AxisTitleStyle}" />
                            </DataTemplate>
                        </chartView:CategoricalAxis.TitleTemplate>
                    </chartView:CategoricalAxis>
                </chart:RadCartesianChart.HorizontalAxis>
 
                <chart:RadCartesianChart.VerticalAxis>
                    <chartView:LinearAxis  Title="VerticalAxis" LabelStyle="{StaticResource AxisLabelStyle}" >
                        <chartView:LinearAxis.TitleTemplate>
                            <DataTemplate>
                                <TextBlock Text="{Binding}" Margin="0,6,0,10" Style="{StaticResource AxisTitleStyle}" />
                            </DataTemplate>
                        </chartView:LinearAxis.TitleTemplate>
                    </chartView:LinearAxis>
                </chart:RadCartesianChart.VerticalAxis>
 
                <chartView:BarSeries ItemsSource="{Binding Inventory.View}" ValueBinding="CountBatch" CategoryBinding="StepPosition" 
StringBinding="Step"
/>                                           </chart:RadCartesianChart>
Petar Marchev
Telerik team
 answered on 29 Mar 2012
3 answers
194 views
Is it possible to make the Grid create a GroupDescriptor instead of a ColumnGroupDescriptor? I modified the header of the grid columns to have buttons that perform actions when the user clicks on them. Now when the user groups by a column I can see the buttons on the grouppanel as well.
Nedyalko Nikolov
Telerik team
 answered on 29 Mar 2012
1 answer
125 views
Hello,

I am seeing a weird behaviour with the TreeListView where it appears that it is creating new items upon calling ExpandAll().  I am curious as to whether this is a known issue, or whether anyone else has seen this too.

I bind my TreeListView to a list that has a total of 87,954 rows.  There are 18,493 top-level rows and the remainder are children (at various depths).  I have exposed a button on the UI that simply calls ExpandAll() on the TreelistView.  After this is clicked, the TreeListView displays a varying numbers of rows, all of which are greater than 87,954.  Each time I launch the app and click the "expand all" button, I get different numbers of rows.  I have seen 88,228, 88,232, 87,985 etc. - each of which is larger than the 87,954 as expected.  I have confirmed that my bound collection has not changed, so I am lead to believe that somehow more items are being created during the expansion process.  I have also noticed that if I try to scroll to the bottom of the TreeListView, it chokes and stops responding for some time before it will allow me to scroll to the bottom.

All these issues make me think that I am seeing a bug in the ExpandAll functionality.  Can anyone confirm?  (I am using the Q3, 2011 build.  I will try the latest build shortly, but I am not at a point in our release where updating is possible.)

Thanks,
Mark
Nedyalko Nikolov
Telerik team
 answered on 29 Mar 2012
2 answers
133 views
The Telerik Work Item Manager application uses Log4Net as its logging component. It defines a configuration section for Log4Net inside the app.config file. The problem I'm having is, we use Log4Net extensively here at this company, and we've already defined Log4Net blocks inside our machine.config files. When Work Item Manager starts up, it sees these conflicting configuration blocks and throws an exception.

Can someone explain how I can work around this to start up Work Item Manager? Perhaps there's a way to disable Log4Net for WIM so it doesn't initialize those components? It seems silly that just because I have Log4Net preconfigured on my machine that I'm not allowed to use this application.
Jake
Top achievements
Rank 1
 answered on 28 Mar 2012
1 answer
115 views
Hi,

I would like to switch between Value and the Percent representation on the chart on the basis of the selection of radio button.
I am sending the data in the form of values in the data set and would like to use some type of content format to achieve this functionality. So that i dont have to code extra for calculating the percentage and sending that to the data set of the RadChart instead.

I am attaching the user interface i have achieved and also the changes for the UI i would like to achieve.

Thanks in advance.
Evgenia
Telerik team
 answered on 28 Mar 2012
2 answers
151 views
I am trying out RadControls for WPF Q1 2012.

When setting up line series for a cartesian chart I set the vertical axis in each series. Some of the series can use the same vertical axis so I assign the same linear axis for the vertical axis in each of those series.
 
Is this the correct way to share a vertical axis between series?

I wonder since if I call Clear() on the chart series after setting things up in this way I get a null reference exception as follows:

System.NullReferenceException was caught
  Message=Object reference not set to an instance of an object.
  Source=Telerik.Windows.Controls.Chart
  StackTrace:
       at Telerik.Windows.Controls.ChartView.Axis.OnDetached(RadChartBase oldChart) in c:\TB\102\WPF_Scrum\Release_WPF\Sources\Development\Controls\Chart\Visualization\Common\Axis.cs:line 582
       at Telerik.Windows.Controls.ChartView.ChartElementPresenter.Detach() in c:\TB\102\WPF_Scrum\Release_WPF\Sources\Development\Controls\Chart\Visualization\Common\ChartElementPresenter.cs:line 93
       at Telerik.Windows.Controls.ChartView.RadChartBase.OnPresenterRemoved(ChartElementPresenter presenter) in c:\TB\102\WPF_Scrum\Release_WPF\Sources\Development\Controls\Chart\Visualization\RadChartBase.cs:line 520
       at Telerik.Windows.Controls.ChartView.CartesianSeries.OnDetached(RadChartBase oldChart) in c:\TB\102\WPF_Scrum\Release_WPF\Sources\Development\Controls\Chart\Visualization\CartesianChart\Series\CartesianSeries.cs:line 161
       at Telerik.Windows.Controls.ChartView.ChartElementPresenter.Detach() in c:\TB\102\WPF_Scrum\Release_WPF\Sources\Development\Controls\Chart\Visualization\Common\ChartElementPresenter.cs:line 93
       at Telerik.Windows.Controls.ChartView.RadChartBase.OnPresenterRemoved(ChartElementPresenter presenter) in c:\TB\102\WPF_Scrum\Release_WPF\Sources\Development\Controls\Chart\Visualization\RadChartBase.cs:line 520
       at Telerik.Windows.Controls.ChartView.PresenterCollection`1.ClearItems() in c:\TB\102\WPF_Scrum\Release_WPF\Sources\Development\Controls\Chart\Visualization\Common\PresenterCollection.cs:line 61
       at XXX.LineChart.SetUpLineChart() in C:\Workspaces\XXX\LineChart.xaml.cs:line 317

The exception doesn't happen if each series has a unique axis.

If this is the correct way of sharing a vertical axis between series then how do I clear the series without getting an exception?
Terry
Top achievements
Rank 1
 answered on 28 Mar 2012
2 answers
232 views
I have developed a custom control for multiple selection in Rad Combobox. Now i want to show the selected items as comma separated string. Can i manipulate the display member of rad combo box at runtime?
<Window.Resources>
        <DataTemplate x:Key="ItemContDataTemplateKey">
            <Grid x:Name="radCmb" Width="210" HorizontalAlignment="Left">
                <Grid.ColumnDefinitions>
                    <ColumnDefinition  Width="20"></ColumnDefinition>
                    <ColumnDefinition  Width="*"></ColumnDefinition>
                </Grid.ColumnDefinitions>
                <CheckBox x:Name="chkSelct" HorizontalAlignment="Left" DataContext="{Binding}" Grid.Column="0" Unchecked="chkSelct_Unchecked" Checked="chkSelct_Checked"></CheckBox>
                <TextBlock x:Name="txtDropDown" Text="{Binding FullName}" Grid.Column="1"></TextBlock>
            </Grid>
        </DataTemplate>
</Window.Resources>
  
<Telerik:RadComboBox Name="radCmbCompany" HorizontalAlignment="Center" Height="25" Width="250" 
                             SelectedValuePath="Id"
                             IsEditable="True"
                             IsReadOnly="True"
                             ItemTemplate="{StaticResource ItemContDataTemplateKey}" 
                             >
  
        </Telerik:RadComboBox>
  
  
//CODE BEHIND
  
public string DisplayMember { get; set; }
  
public static readonly DependencyProperty SelectedItemsProperty =
        DependencyProperty.Register("SelectedItems", typeof(ObservableCollection<object>), typeof(Window1),
        new FrameworkPropertyMetadata(new ObservableCollection<object>()));
        public ObservableCollection<object> SelectedItems
        {
            get { return (ObservableCollection<object>)base.GetValue(SelectedItemsProperty); }
            set { base.SetValue(SelectedItemsProperty, value); }
        }
  
        public static readonly DependencyProperty SelectedTextProperty =
        DependencyProperty.Register("SelectedText", typeof(string), typeof(Window1),
        new FrameworkPropertyMetadata());
        public string SelectedText
        {
            get { return (string)base.GetValue(SelectedTextProperty); }
            set { base.SetValue(SelectedTextProperty, value); }
        }
private void chkSelct_Checked(object sender, RoutedEventArgs e)
        {
            SetSelectedText(sender);
        }
  
        private void chkSelct_Unchecked(object sender, RoutedEventArgs e)
        {
            SetSelectedText(sender);
        }
  
private void SetSelectedText(object sender)
        {
            CheckBox chkbx = sender as CheckBox;
  
            if (chkbx != null && chkbx.IsChecked.Equals(true))
            {
                this.SelectedItems.Add(chkbx.DataContext);
                string CurrentselectedText = Convert.ToString(chkbx.DataContext.GetType().GetProperty(this.DisplayMember).GetValue(chkbx.DataContext, null));
                if (this.SelectedText != null && this.SelectedText.Length > 0)
                {
                    this.SelectedText += "," + CurrentselectedText;
                }
                else
                {
                    this.SelectedText = CurrentselectedText;
                }
            }
            else if (chkbx != null && chkbx.IsChecked.Equals(false))
            {
                string CurrentselectedText = Convert.ToString(chkbx.DataContext.GetType().GetProperty(this.DisplayPath).GetValue(chkbx.DataContext, null));
                if (this.SelectedText != null && this.SelectedText.Length > 0 && this.SelectedText.IndexOf(',') > 0)
                {
                    if (this.SelectedText.IndexOf(CurrentselectedText) + CurrentselectedText.Length < this.SelectedText.Length && this.SelectedText.Substring(this.SelectedText.IndexOf(CurrentselectedText) + CurrentselectedText.Length, 1) == ",")
                    {
                        this.SelectedText = this.SelectedText.Remove(this.SelectedText.IndexOf(CurrentselectedText), CurrentselectedText.Length + 1);
                    }
                    else
                    {
                        this.SelectedText = this.SelectedText.Remove(this.SelectedText.IndexOf(CurrentselectedText) + 1, CurrentselectedText.Length);
                    }
                }
                else if (this.SelectedText != null && this.SelectedText.Length > 0)
                {
                    this.SelectedText = string.Empty;
                }
            }
        }
gans
Top achievements
Rank 1
 answered on 28 Mar 2012
3 answers
533 views
Hi Telerik:
How can I hide the entire group header column (the bottom level only) as pointed in the screenshot below? I have attached xaml for your reference.

Thanks,
Cheau





        <!-- ScheduleView -->

        <telerik:RadScheduleView x:Name="scheduleView"

                                Grid.Row="2"                                

                                MaxTimeRulerExtent="500"

                                AppointmentsSource="{Binding Tasks, Mode=TwoWay}"

                                ResourceTypesSource="{Binding ScheduleOptionList, Mode=TwoWay}"

                                GroupDescriptionsSource="{Binding GroupCollection, Mode=TwoWay}"

                                CurrentDate="{Binding DefaultDate}"                                              

                                NavigationHeaderVisibility="Collapsed"                               

                                AllowDrop="True"

                                SnapAppointments="True"  

                                MinAppointmentWidth="22"

                                Height="Auto">

 

            <telerik:RadScheduleView.DragDropBehavior>

                <local:ScheduleDragDropBehavior/>

            </telerik:RadScheduleView.DragDropBehavior>

 

            <telerik:RadScheduleView.AppointmentItemContentTemplate>

                <DataTemplate>

                    <StackPanel>

                        <TextBlock Text="{Binding Subject}"  FontWeight="Bold"/>

                        <StackPanel Orientation="Horizontal">

                            <TextBlock Text="{Binding Start, StringFormat={}{0:H:mm}}"/>

                            <TextBlock Text=" - "/>

                            <TextBlock Text="{Binding End, StringFormat={}{0:H:mm}}"/>

                        </StackPanel>

                    </StackPanel>

                </DataTemplate>

            </telerik:RadScheduleView.AppointmentItemContentTemplate>

 

            <telerik:RadScheduleView.ActiveViewDefinition>

                <telerik:DayViewDefinition Orientation="Horizontal" FirstDayOfWeek="Monday" TimerulerMajorTickStringFormat="{}{0:HH}"

                                            MinorTickLength="1h"  MajorTickLength="1h" MinTimeRulerExtent="700" GroupHeaderDateStringFormat="{}{0:MM/dd}" />

               

            </telerik:RadScheduleView.ActiveViewDefinition>                      

 

        </telerik:RadScheduleView>

 

Yana
Telerik team
 answered on 28 Mar 2012
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
LayoutControl
ProgressBar
Sparkline
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
SplashScreen
Callout
Rating
Accessibility
CollectionNavigator
Localization
AutoSuggestBox
Security
VirtualKeyboard
HighlightTextBlock
TouchManager
StepProgressBar
Badge
OfficeNavigationBar
ExpressionParser
CircularProgressBar
SvgImage
PipsPager
SlideView
AI Coding Assistant
+? more
Top users last month
Bohdan
Top achievements
Rank 3
Iron
Iron
Iron
Rob
Top achievements
Rank 3
Bronze
Bronze
Iron
Elliot
Top achievements
Rank 1
Iron
Iron
Iron
Sunil
Top achievements
Rank 1
Cynthia
Top achievements
Rank 1
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Bohdan
Top achievements
Rank 3
Iron
Iron
Iron
Rob
Top achievements
Rank 3
Bronze
Bronze
Iron
Elliot
Top achievements
Rank 1
Iron
Iron
Iron
Sunil
Top achievements
Rank 1
Cynthia
Top achievements
Rank 1
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?