Telerik Forums
UI for WPF Forum
0 answers
264 views
How do I convert the following xaml in code:

<telerik:GridViewDataColumn.CellStyleSelector>
                        <telerik:ConditionalStyleSelector>
                            <telerik:StyleRule Condition="UnitPrice > 10">
                                <Style TargetType="telerik:GridViewCell"
                                       BasedOn="{StaticResource GridViewCellStyle}">
                                    <Setter Property="Background"
                                            Value="{StaticResource AccentBrush}" />
                                    <Setter Property="Foreground"
                                            Value="{StaticResource MainBrush}" />
                                </Style>
                            </telerik:StyleRule>
                            <telerik:StyleRule Condition="UnitPrice &lt;= 10">
                                <Style TargetType="telerik:GridViewCell"
                                       BasedOn="{StaticResource GridViewCellStyle}" />
                            </telerik:StyleRule>
                        </telerik:ConditionalStyleSelector>
                    </telerik:GridViewDataColumn.CellStyleSelector>

Oliver
Top achievements
Rank 1
 asked on 27 Feb 2013
0 answers
111 views

I'm using the MVVM pattern such that I've got a comboboxColumn bound to a datasource.

My intention was whatever the user select, it should update the description of another column. At the moment it is not updating. The underlying data has changed but not refreshed.

What am I missing?

Oliver
Top achievements
Rank 1
 asked on 27 Feb 2013
5 answers
241 views
What I'd like to achieve is like these two image attachments which were created in Excel. I'd like to have two levels of X-Axis labelling. I'd also like to have clustered and stacked.

Is this possible with the Telerik WPF charting tools?
Nikolay
Telerik team
 answered on 27 Feb 2013
1 answer
117 views
Hi,

Firstly I must point out that this is to do with vs2010 and 2012 rather than a telerik product.

I have the following code:

private void treeMenuItemEditProduct_Click(object sender, RadRoutedEventArgs e)
{
 
    if (this.treeProducts.SelectedItem != null)
    {
        RadTreeViewItem treeViewItem = (RadTreeViewItem)treeProducts.SelectedItem;
        Products selectedProduct = treeViewItem.Tag as Products;
 
        EditProductsWindow editProductWindow = new EditProductsWindow(selectedProduct);
        editProductWindow.Owner = Window.GetWindow(this);
        editProductWindow.IsRestricted = true;
        editProductWindow.WindowStartupLocation = WindowStartupLocation.CenterOwner;
        editProductWindow.ShowDialog();
        //Check if the closing window achieved or failed its task
        if (editProductWindow.DialogResult == true)
        {
            //Get collection Index of selected product
            int index = TAS2Database.DBTimers.GetProducts.EnabledProducts.IndexOf(selectedProduct);
            //Remove Selected Product from List
            TAS2Database.DBTimers.GetProducts.EnabledProducts.Remove(selectedProduct);
            //Add new Product to Products List
            TAS2Database.DBTimers.GetProducts.EnabledProducts.Insert(index, editProductWindow.newProduct);
 
            //Amend TreeViewItem
            treeViewItem.Tag = editProductWindow.newProduct;
            treeViewItem.Header = editProductWindow.newProduct.Name.ToString();
            treeViewItem.ToolTip = editProductWindow.newProduct.ID.ToString();
        }
    }
    else
    {
        RadWindow.Alert("Please select a product to edit.");
    }
}


When I execute the following line of code for a second time in VS2012 I get a return value of -1, where as in VS2010 in works fine every time.

//Get collection Index of selected product
int index = TAS2Database.DBTimers.GetProducts.EnabledProducts.IndexOf(selectedProduct);
 
When I say a second time, I mean that I execute the "click" function once and all works well, but when the click executes a second time, then I keep on getting a return value of -1. As I previously mentioned, this problem does not exist when using VS2010.

Does anyone have any ideas of why this may be?

Thank you very much for your time taken to read this and I look forward to any responses that you may have.

Rob





Robert
Top achievements
Rank 1
 answered on 27 Feb 2013
0 answers
73 views
Hi there,

can arbitrary controls, in my case RadGridView Controls, be embbeded in a cell?

I need a control, where the first column represents a hierarchie and the second colum contains a list of items for each hierarchie-level.

The nested / grouped RadGridView looks similiar, however I need the group to be in another column. Like this:

hierarchy  |      items
==============================
root       |         
------------------------------
 > child   |  -------------
        |  |item 1 | 1 |
        |  |item 2 | 2 |
        |  -------------
------------------------------

Thanks for any hints!

Cheers,

Jan
Jan
Top achievements
Rank 1
 asked on 26 Feb 2013
3 answers
227 views
Hi.

I've been using Telerik controls for a while, and with the latest release, RadDatePicker throws a NullReferenceException after opening the dropdown of the control, configured with DateSelectionMode= "Month".

This happens on  Telerik RadControls for WPF 2013.1.220.40

Could you fix this problem?

XAML Code:

<telerik:RadDatePicker Name="MonthRDP" Grid.Column="1" DateSelectionMode="Month"  />

StackTrace: 

en Telerik.Windows.Controls.RadCalendar.PopulateMonths() en c:\TB\135\WPF_Scrum\Release_WPF\Sources\Development\Controls\Input\Calendar\RadCalendar.cs:línea 3644
en Telerik.Windows.Controls.RadCalendar.UpdateCalendarViews() en c:\TB\135\WPF_Scrum\Release_WPF\Sources\Development\Controls\Input\Calendar\RadCalendar.cs:línea 2723
en Telerik.Windows.Controls.RadDateTimePicker.OnIsDropDownOpenChanged() en c:\TB\135\WPF_Scrum\Release_WPF\Sources\Development\Controls\Input\DateTimePicker\RadDateTimePicker.cs:línea 1297
en Telerik.Windows.Controls.RadDateTimePicker.OnIsDropDownOpenChanged(DependencyObject d, DependencyPropertyChangedEventArgs e) en c:\TB\135\WPF_Scrum\Release_WPF\Sources\Development\Controls\Input\DateTimePicker\RadDateTimePicker.cs:línea 1221
en System.Windows.DependencyObject.OnPropertyChanged(DependencyPropertyChangedEventArgs e)
en System.Windows.FrameworkElement.OnPropertyChanged(DependencyPropertyChangedEventArgs e)
en System.Windows.DependencyObject.NotifyPropertyChange(DependencyPropertyChangedEventArgs args)
en System.Windows.DependencyObject.UpdateEffectiveValue(EntryIndex entryIndex, DependencyProperty dp, PropertyMetadata metadata, EffectiveValueEntry oldEntry, EffectiveValueEntry& newEntry, Boolean coerceWithDeferredReference, Boolean coerceWithCurrentValue, OperationType operationType)
en System.Windows.DependencyObject.SetValueCommon(DependencyProperty dp, Object value, PropertyMetadata metadata, Boolean coerceWithDeferredReference, Boolean coerceWithCurrentValue, OperationType operationType, Boolean isInternal)
en MS.Internal.Data.PropertyPathWorker.SetValue(Object item, Object value)
en MS.Internal.Data.ClrBindingWorker.UpdateValue(Object value)
en System.Windows.Data.BindingExpression.UpdateSource(Object value)

Thanks


Szymon
Top achievements
Rank 1
 answered on 26 Feb 2013
2 answers
93 views
I'm setting current culture during application startup:
Thread.CurrentThread.CurrentCulture = new CultureInfo("en-GB");
Thread.CurrentThread.CurrentUICulture = new CultureInfo("en-GB");

Then on Grid I have following column

<telerik:GridViewDataColumn DataMemberBinding="{Binding Path=StartDate}" Header="Start Date" DataFormatString="d" IsSortable="True" />

On version 2012 Q2, Grid displayed this column in en-GB format, but after update it uses en-US. All other controls (like date picker) are displaying date correctly. Only grid has problem.
Dimitrina
Telerik team
 answered on 26 Feb 2013
2 answers
429 views
Hi,

When I have a GridViewDataColumn of type "double", it is displayed with a "." as decimal separator, disregarding the localization settings (where in my case "," is the decimal separator).  On the other hand, the filtering of the colum does look at the localization.
So the users sees for instance 1.51 in the column, but has to type 1,5 in the filter textbox, or otherwise a error is generated (which is very confusing to the user).  Or maybe I am missing something here ?

Kind regards,

Martin
Dimitrina
Telerik team
 answered on 26 Feb 2013
4 answers
181 views
I am not sure if this is reporting issue or docking issue. (I did not see a forum for WPF Reporting)

I have an issue using the Telerik reporting Q3 2012 (SP1) Specifically the Telerik.ReportViewer.Wpf.dll (version 6.2.13.123)

I create a WPF application
On the MainWindow.xaml, I add RadDocking as follows:
 <Grid>
   <telerik:RadDocking>  
     <telerik:RadSplitContaier> 
       <telerik:RadPaneGroup>
        <telerik:RadPane>
           <tr:ReportViewer />
        </telerik:RadPane>
       </telerik:RadPaneGroup>
     </telerik:RadSplitContaier> 
   </telerik:RadDocking>   
 </Grid>

When I run this, the main window opens fine. Now drag the window and dock it somewhere in the main window.
The result is an exception (NullReferenceException) the stack trace mentions the ReportViewerModel.SetReportSourceEffective (ReportViewerModel.cs line 983) 

Note: This seems to be an issue with the SP 1 dll because this example code runs fine when using the Telerik reporting Q3 2012 dlls (i.e Telerik.ReportViewer.Wpf.dll  version 6.2.12.1017)

Help?
Mark
Top achievements
Rank 1
 answered on 26 Feb 2013
1 answer
172 views

Hi,

We have a situation where we need to style the RadPieChart so that it appears as shown in the attached mockup. As you can see, the selected slice of the Pie Chart has a 3D-like appearance whereas the remaining slices appear in 2D, and this is where we got stuck and didn’t know how to style something like that. Is there any way to modify the control template of the “selected slice”? But then, how do we display other selected slices to have such an edge when they are selected?

Screenshot of the pie chart is attached please check 



thanks in advance,
Srinivas.
Petar Kirov
Telerik team
 answered on 26 Feb 2013
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
Cynthia
Top achievements
Rank 1
Iron
Toby
Top achievements
Rank 3
Iron
Iron
Iron
Danielle
Top achievements
Rank 1
Iron
Iron
Joel
Top achievements
Rank 3
Bronze
Bronze
Iron
yw
Top achievements
Rank 2
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Cynthia
Top achievements
Rank 1
Iron
Toby
Top achievements
Rank 3
Iron
Iron
Iron
Danielle
Top achievements
Rank 1
Iron
Iron
Joel
Top achievements
Rank 3
Bronze
Bronze
Iron
yw
Top achievements
Rank 2
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?