Telerik Forums
UI for WPF Forum
4 answers
359 views

It seems that all what the IsGrouped property does is decide if the properties appeared as grouped or not, and clicking on A-Z doesn't sort them from A-Z (unlike for example in Visual Studio).

I've created an example where the item is:

public class MyClass
{
    [Display(Name="A-Name", GroupName="Group2", Order=9)]
    public string AName { get; set; }
 
    [Display(Name="B-Name", GroupName="Group2", Order=7)]
    public string BName { get; set;}
 
    [Display(Name = "C-Name", GroupName = "Group2", Order = 8)]
    public string CName { get; set; }
 
    [Display(Name = "D-Name", GroupName = "Group1", Order = 3)]
    public string DName { get; set; }
 
    [Display(Name = "E-Name", GroupName = "Group1", Order = 2)]
    public string EName { get; set; }
 
    [Display(Name = "F-Name", GroupName = "Group1", Order = 1)]
    public string FName { get; set; }
 
}

 

When the A-Z button is selected, the properties are ordered as:

F-Name

E-Name

D-Name

B-Name

C-Name

A-Name

 

 

Just like the order I've defined. But with any other normal property grid, the order only affects the items when they are grouped.

The visibility of these buttons is called "SortAndGroupButtonsVisibility", so theoretically, this button should have sorted the properties alphabetically.

 

Stefan Nenchev
Telerik team
 answered on 20 Jul 2016
1 answer
84 views

Hi,

I'm unable to get the dialogs to show up while using implicit theming with Office2013. Please see the attached image and zip file with the sample solution.

I made sure to include the required DLLs and use MEF loading. Can you please indicate what's missing?

Without the dialogs the word processor cannot be used.

Thanks

aronluc28
Top achievements
Rank 1
 answered on 20 Jul 2016
2 answers
192 views
Good morning
I am using the SHOWSEARCHPANEL properties datagridview component and I would need to tie me to the click event of the search textbox.
Can you help me?
Thank you
Burato
Top achievements
Rank 1
 answered on 20 Jul 2016
1 answer
177 views

Hi,

If you set the Item to an IEnumerable, the control strips away all the Attributes of the source properties. For example, the DisplayNameAttribute, or the DescriptionAttribute (all of them). So, what you get is with one item, you see the display names of properties as declared in the class, but then if you supply a List of 2 items, all the display names are shown as the original property name. Kind of odd.

To further confirm, if I hook onto the AutoGeneratingPropertyDefinition event, and I want to add logic like suppress a property if it has the MergableProperty(false) attribute, well, I can't, because the PropertyDefinition.SourceProperty.Descriptor you supply has no Attributes. The collection is empty. You've supplanted the original PropertyDescriptor with a PropertySetPropertyDescriptor that has stripped away much useful information.

Luckily, I can work around all of these problems by matching up property names with the original PropertyDescriptors for the given type, and then fixing up the property definitions, but I don't know, I think you can do this a lot better.

Also, it seems necessary to have to switch the PropertySetMode between 'None' and 1 of the other choices when going from single item to multiple items. Why? Why can't the logic be smart enough to say, if Item is not an IEnumerable, then do single item properties, else if multiple items, then do multi-item logic. The property should not need to change. Changing PropertySetMode causes an internal Refresh, so we must set Item to null first. There are other quirky behaviors I've noticed when going to and from single-item mode and multi-item mode, like with the CategoryAttribute, it can stick in the UI when in Grouped mode, even though the Category heading should disappear, but I'll wait to see what you say to all of this.

 

 

 

Stefan
Telerik team
 answered on 20 Jul 2016
1 answer
237 views

Create a couple of RadPanes in one RadPaneGroup so that it shows the tab headers. Create another RadPaneGroup with a RadPane.

Put a RadTreeView in the first RadPane, populate with some items.

OK, select 1 of the TreeView items.

1. If you click on the RadPane header in the separate group to activate it, the selected TreeView item will switch to "SelectedUnfocused" state (turns gray).

2. Click back on the TreeView item to focus it again.

3. This time, click on the other RadPane tab in the same group. Click back on the pane tab header with the TreeView. In this case, the TreeView item is still blue (in a SelectedFocused state). But it actually is not "focused". At least not keyboard focused, so it should be gray.

 

Code I found :)

If you look in Docking.PaneHeader.OnMouseLeftButtonDown(), when the user selects a RadPaneGroup, Focus() will be called on that group. That is why the RadTreeViewItem turns gray in the first test.

But no such "Focus()" call can be found when only a RadPane is activated. To fix, I put a Focus() call in RadDocking.ActivePaneChanged event, but you may want to do it differently. :)

 

 

 

Polya
Telerik team
 answered on 20 Jul 2016
4 answers
130 views
Any picture inserted in header section are not shown when it's exported to pdf using PdfFormatProvider. Is there any solution?
Boby
Telerik team
 answered on 20 Jul 2016
1 answer
66 views

Hello All,
     I have been tasked in a WPF/MVVM application to setup a TreeListView that shows some "Property/Value" pairs.  For most of the properties, the value should be a simple textbox, but for some of the particular properties, the values should be displayed as a dropdown selection.  Is there a way to get this done.  I'm starting down the path of in the table that stores these property/value pairs, have a column that designates what type of "Value" cell show be displayed, the by using that setting up a CellEditTemplate to properly configure the cell as either a textbox or dropdown...  Having never created a CellEditTemplate before, I wasn't sure if this is possible or even the correct path to venture down...  So, there's my dilemma/question...  If this is the correct path, is there a good example of how to get this done???

 

Thanks in advance,

Kevin Orcutt
Senior Software Engineer

Wurth Electronics ICS, Inc.
7496 Webster St., Dayton, OH 45414
Tel: 937.415.7700 
Toll Free: 877.690.2207
Fax: 937.415.7710
Email: Kevin.Orcutt@we-ics.com
http://www.we-ics.com

Stefan
Telerik team
 answered on 20 Jul 2016
4 answers
2.3K+ views

Hi people,

I have problem with RadGridView and background color: I can't set it ! I have a MVVM application and the grid is bind with observable collection; all my data are displayed correctly:

<telerik:RadGridView x:Name="dataGrid" ItemsSource="{Binding Model, UpdateSourceTrigger=PropertyChanged, Mode=TwoWay}" AutoGenerateColumns="False" FrozenColumnCount="1" CanUserDeleteRows="False" CanUserInsertRows="False" GroupRenderMode="Flat" ShowGroupPanel="False" ClipboardPasteMode="Default" SelectionMode="Extended" SelectionUnit="Cell" >
 
<telerik:GridViewDataColumn Header="Data" DataMemberBinding="{Binding Date}" DataFormatString="{} {0:dd/MM/yyyy}" IsReorderable="False" IsSortable="False" IsFilterable="False" IsReadOnly="True" Width="80" />
 
<telerik:GridViewDataColumn Header="Flow" DataMemberBinding="{Binding Flow}" IsSortable="False" IsFilterable="False" IsReadOnly="True" Width="110" />

Now I want to color the row and bind it to property named UserInput (boolean) using converter like this:

internal class UserInputConveter : IValueConverter
    {
        public object Convert(object value, Type targetType, object parameter, System.Globalization.CultureInfo culture)
        {
            var userInput = (bool)value;
 
            if (userInput)
                return new SolidColorBrush(Colors.GreenYellow);
 
            return new SolidColorBrush(Colors.Transparent);
        }
 
        public object ConvertBack(object value, Type targetType, object parameter, System.Globalization.CultureInfo culture)
        {
            throw new NotImplementedException();
        }
    }

But it doesn't work. I tried:

1)

<telerik:RadGridView.RowStyle>
    <Style TargetType="telerik:GridViewRow">
        <Setter Property="Background" Value="{Binding UserInput,Converter={StaticResource UserInputConveter}}"></Setter>
    </Style>
</telerik:RadGridView.RowStyle>

Result: all my rows disappear!

2)

<telerik:GridViewDataColumn.CellStyle>
    <Style TargetType="telerik:GridViewCell">
        <Setter Property="Background" Value="{Binding Path=UserInput, Converter={StaticResource UserInputConveter}}"></Setter>
    </Style>
</telerik:GridViewDataColumn.CellStyle>

Result: my single cell disappear.

3)

<telerik:GridViewDataColumn Header="Flow" DataMemberBinding="{Binding Flow}" IsSortable="False" IsFilterable="False" IsReadOnly="True" Width="110" Background="{Binding Path=UserInput, Converter={StaticResource userInputConverter}}" />

OR

<telerik:GridViewColumn.Background>
    <SolidColorBrush Color="{Binding Path=UserInput, Converter={StaticResource userInputConverter}}" />
</telerik:GridViewColumn.Background>

Result: the color of cell is thedefault, no change.

Where is my error? How I can do it?

Thanks a lot.

Stefan
Telerik team
 answered on 19 Jul 2016
1 answer
114 views

Is there a way to initialize a map to a specific position without having to see the map rapidly pan and zoom?

I have a set of items in a VisualizationLayer and I would like to display those items on the map without scrolling and zooming. The layer is bound to a list in the xaml.

Currently, I set the bounds by calling GetBestView() on the VisualizationLayer to get the precise boundaries. This works, but the map starts at coordinates 0,0 and then scrolls and zooms. It does this for several seconds - the appearance is very annoying to the user. 

I would like to be able to set the bounds directly and have the map go straight to the area without scrolling and zooming. It may be that I am not setting the bounds at the appropriate time?

Is this even possible?

Dinko | Tech Support Engineer
Telerik team
 answered on 19 Jul 2016
1 answer
218 views
I have a StatusPicture shape class, which has an observablecollection of ValuePairs inside it. When I copy and paste these statuspicture shapes, the items of observablecollection won't appear in the new shape. How could this be done?
Stefan Nenchev
Telerik team
 answered on 19 Jul 2016
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?