Telerik Forums
UI for WPF Forum
5 answers
604 views
I am using Implicit Themes in my WPF app, like so:
<Application x:Class="Green.App"
    xmlns:local="clr-namespace:Green">
    <Application.Resources>
      <ResourceDictionary>
            <ResourceDictionary.MergedDictionaries>
                <ResourceDictionary>
                    <local:AppBootstrapper x:Key="bootstrapper" />
                </ResourceDictionary>
                <ResourceDictionary Source="/Telerik.Windows.Themes.Windows8;component/Themes/System.Windows.xaml"/>
                <ResourceDictionary Source="/Telerik.Windows.Themes.Windows8;component/Themes/Telerik.Windows.Controls.xaml"/>
                <ResourceDictionary Source="/Telerik.Windows.Themes.Windows8;component/Themes/Telerik.Windows.Controls.Input.xaml"/>
                <ResourceDictionary Source="/Telerik.Windows.Themes.Windows8;component/Themes/Telerik.Windows.Controls.Navigation.xaml"/>
            </ResourceDictionary.MergedDictionaries>
        </ResourceDictionary>
    </Application.Resources>
</Application>

It doesn't seem to be applying to User Controls that I create, do I need to do something different?  I noticed here -->Implicit Styles that it references using the "Themes.Implicit" folder...

I did what I have shown above and added a reference to "Telerik.Windows.Themes.Windows8", the No Xaml version.
Vanya Pavlova
Telerik team
 answered on 01 May 2013
3 answers
121 views
Hello,

In my wpf application i've a feature of drag and drop of grid view rows and i need to add an image to one cell in the row dragged.

To do this, i create the image object dynamically with this code:
           
var cellImage = new Image() { Width = 20, Height = 20 };
var imageUri = "../AppResources/Images/flag.png";
cellImage.Source = new System.Windows.Media.Imaging.BitmapImage(new Uri(imageUri, UriKind.Relative));


And i add the image to the cell i want:
this.jobsGridView.CurrentCell.ParentRow.Cells[2].Content = cellImage;

The image is added to the cell of the dragged row but also added to some other rows in the gridview.

Do you know the cause of this behavior?

Thanks.
Nick
Telerik team
 answered on 01 May 2013
3 answers
296 views
Hi!

I'm trying to get RadListBox accept items from RadTreeView but my RadListBox does not seem to accept drops from TreeView. Do I need to have somekind of converter even though the actual payload object is same as what I have loaded in the listbox. In treeview I'm using HierarchicalDataTemplate which shows individual users (User class) with some data from related entity tables. ListBox only shows user's username but it uses the same User class.

        <Style x:Key="DraggableListBoxItem" TargetType="telerik:RadListBoxItem">
            <Setter Property="telerik:DragDropManager.AllowCapturedDrag" Value="True"/>
            <Setter Property="telerik:DragDropManager.AllowDrag" Value="True" />
            <Setter Property="telerik:DragDropManager.TouchDragTrigger" Value="TapAndHold"/>
        </Style>
         
        <DataTemplate x:Key="ListBoxItemTemplate">
            <Grid>
                <Grid.ColumnDefinitions>
                    <ColumnDefinition Width="Auto"/>
                    <ColumnDefinition Width="Auto"/>
                </Grid.ColumnDefinitions>
                <Image Source="/Dashboard_UserExtension;component/Images/usericon.png" Margin="10 0 0 0" Width="16" Height="16" Grid.Column="0"
                        HorizontalAlignment="Left" />
                <TextBlock Text="{Binding Username}" FontSize="12" FontFamily="Segoe UI" Grid.Column="1" Margin="10 0 0 0" HorizontalAlignment="Left" />
            </Grid>
        </DataTemplate>
 
<telerik:RadListBox
                x:Name="AdminUserBox"
                AllowDrop="True"
                ItemTemplate="{StaticResource ListBoxItemTemplate}"
                ItemContainerStyle="{StaticResource DraggableListBoxItem}"
                HorizontalAlignment="Left"
                Margin="0,10,0,1"
                Width="150"
                ItemsSource="{Binding AdminUserList}" Drop="AdminUserBox_Drop">
                <telerik:RadListBox.DragVisualProvider>
                    <telerik:ScreenshotDragVisualProvider />
                </telerik:RadListBox.DragVisualProvider>
                <telerik:RadListBox.DragDropBehavior>
                    <telerik:ListBoxDragDropBehavior AllowReorder="True" />
                </telerik:RadListBox.DragDropBehavior>
            </telerik:RadListBox>
 
<telerik:RadTreeView x:Name="UserTreeView"
                                 HorizontalAlignment="Left"
                                 Margin="0,10,-2,0"
                                 Width="220"
                                 IsDragDropEnabled="True"
                                 ItemTemplate="{StaticResource UserTemplate}"
                                 ItemsSource="{Binding UserList}"
                                 IsLoadOnDemandEnabled="False"
                                 IsSingleExpandPath="True"
                                 ItemContainerStyle="{StaticResource UsersItemContainerStyle}"
                                 AllowDrop="False"
                                 >
            </telerik:RadTreeView>


My other problem is how to handle drop event when dragging item from listbox to another listbox. Both listbox have AllowDrop=true and items can be dropped to each other but I'm not sure how to handle drop event as it does not seem to fire on drop. Do I need to use this DragAndDropManager?

private void AdminUserBox_Drop(object sender, System.Windows.DragEventArgs e)
{
    MessageBox.Show("Drop!"); // Not shown when dropping to AdminUserBox
}

Drag and Drop problems

I tried to follow Telerik's DragAndDrop samples but I'm little bit confused if I should use DragAndDropManager or not...

I just saw a post about renewing the RadTreeView, maybe I need to wait for that.

Br,

Kalle
Nick
Telerik team
 answered on 01 May 2013
1 answer
134 views
Hi,

The TimeLine items randomly positioned on the rows.
- Group 1
XXXXXXXXXXXX   O   O   O    O   O   O     O   O   O
         XXXXXXXXXXXX XXXXXXXXXXXX  
               
+ Group 2

Is it possible to choose a row item ? I must have a period followed by several events without duration on each row in the same group :

- Group 1
XXXXXXXXXXXX   O   O   O
         XXXXXXXXXXXX    O   O   O
                  XXXXXXXXXXXX   O  O  O

+ Group 2

Tsvetie
Telerik team
 answered on 01 May 2013
2 answers
165 views
 I have to GridViewDataColumns in a single grid.  Both have DataMemberBinding set. Both display the information in the grid however filtering does not work on the second one. The only difference betweend the two is one has a long Path than the other. Are there any known bugs with this and is there a work around?

This one works
   <telerik:GridViewDataColumn Width="75"
                                                    MinWidth="75"
                                                    DataMemberBinding="{Binding Path=PaymentSubTypeDetail.PurchaseBased}"
                                                    Header="%"
                                                    IsFilterable="True"
                                                    IsSortable="True" />

This one doesn't work
<telerik:GridViewDataColumn Width="*"
                                                    MinWidth="100"
                                                    DataMemberBinding="{Binding  Path=PaymentSubTypeDetail.ReceiptTicketStyle.Name}"                                                  
                                                    Header="Receipt Style"
                                                    IsFilterable="True"
                                                    IsSortable="True" / >
                       
               
Dimitrina
Telerik team
 answered on 01 May 2013
1 answer
126 views
I have an issue with highlighting an item when typing in the combobox. It's reproducible with the WPF Controls Examples like this:

- Open WPF Controls Examples
- All controls
- Select combobox demo
- In more ComboBox Examples select the Data Binding example
- Click on the top combobox (The not editable sample)
- Type PB
- The item 'PB knackebrod AB' should be highlighted, but it's not
- Press enter
- The tem 'PB knackebrod AB' is selected

So it does find the correct item, but does not highlight it.

Could you please fix this?
George
Telerik team
 answered on 01 May 2013
3 answers
121 views
Hello,
I'm mainly using Summer theme as implicit styles. However I realized that System.Windows.xaml of this theme is causing exception in WPF designer on Visual Studio 2012. When I'm exclude these styles from resources everything is correct, after including I have crash again. I've started testing and realized that this is happening with summer theme but e.g. Windows8 is working without issue. I've checked office and it has the same issue. The issue is only with System.Windows.xaml  file. I tried to find where it is but I couldn't

There is other issue that I have which is related to .NET 4 and Visual Studio 2010:
in your implicit styles there can be found e.g. following clause:
<DiscreteObjectKeyFrame.Value>
<Thickness>0,0,-1,0</Thickness>
</DiscreteObjectKeyFrame.Value>
Becaue I'm using Polish operating system designer (becuase of VS bug) cannot parse this (it doesn't like commas). Could you please change commas to spaces? Which is proper as well and you already using that in most places but not always. I can find examples where commas can be found. It is taking me a lot of time to upgrade project properly becuase I need to take care with this bug.
Vanya Pavlova
Telerik team
 answered on 01 May 2013
1 answer
597 views
I couldn't able to apply rounded corners to the SubMenu's in the RadContextMenu. I do like to know how to set the minwidth for submenu just like in the TopLevelMenu and How to change the highlightcolor. Any help would be great. Thank you in advance.
<Window.Resources>       
        <Style x:Key="MenuItemStyle" TargetType="{x:Type telerik:RadMenuItem}">
            <Setter Property="Icon" Value="{Binding Icon}" />
            <Setter Property="IsSeparator" Value="{Binding IsSeparator}" />           
        </Style>
        <Style x:Key="ContextMenuStyle" TargetType="telerik:RadContextMenu">
            <Setter Property="Template">
                <Setter.Value>
                    <ControlTemplate TargetType="telerik:RadContextMenu">
                        <Border CornerRadius="5" BorderBrush="Gray" BorderThickness="1" Background="White" SnapsToDevicePixels="True">
                            <ItemsPresenter />
                        </Border>
                    </ControlTemplate>
                </Setter.Value>
            </Setter>
        </Style>
    </Window.Resources>
    <Grid>
        <Border Background="Gray" >
            <telerik:RadContextMenu.ContextMenu>
                <telerik:RadContextMenu x:Name="textcontext" IconColumnWidth="0" MinWidth="150" 
                                        Style="{StaticResource ContextMenuStyle}" HorizontalAlignment="Right"
                                        NotifyOnHeaderClick="True" ItemContainerStyle="{StaticResource MenuItemStyle}" ItemsSource="{Binding}" >
                    <telerik:RadMenuItem Header="New" />
                    <telerik:RadMenuItem IsSeparator="True" />
                    <telerik:RadMenuItem Header="Edit" >
                        <telerik:RadMenuItem Header="New" />
                        <telerik:RadMenuItem IsSeparator="True" />
                        <telerik:RadMenuItem Header="Edit">
                            <telerik:RadMenuItem Header="New" />
                            <telerik:RadMenuItem IsSeparator="True" />
                            <telerik:RadMenuItem Header="Edit"/>
                            <telerik:RadMenuItem Header="Delete" />
                            <telerik:RadMenuItem Header="Select" />
                        </telerik:RadMenuItem>
                        <telerik:RadMenuItem Header="Delete" />
                        <telerik:RadMenuItem Header="Select" />
                    </telerik:RadMenuItem>                                    
                    <telerik:RadMenuItem Header="Delete" />
                    <telerik:RadMenuItem IsSeparator="True" />
                    <telerik:RadMenuItem Header="Select" />
                </telerik:RadContextMenu>
            </telerik:RadContextMenu.ContextMenu>
        </Border>
    </Grid>



Hristo
Telerik team
 answered on 01 May 2013
1 answer
303 views
Hi,
The problem:
  On the click of a row I have to show the child records (more suitable for HierarchicalTemplate but for some unknown reasons it failed in our project, though worked in the demo I prepared). Basically it seems that the row is not expanding to show rowDetailTemplate which contains another radgridview. The issue was due to some properties in style. I don't find a link to delete, please delete this link. I am facing another issue but will open an appropriate thread.

So I am using RowDetailsTemplate, which contains RadGridView  again. I have moved binding logic from the XAML file to code behind for testing in the OnRowDetailsVisibilityChanged. The problem is binding is working fine in all the cases, but detail grid shows exactly over the parent row. I am attaching the image. I have trying doing the same with GridViewToggleRowDetailsColumn but result is the same. Here is my grid Code and thanks in advance for the help.

<telerik:RadGridView  Name="gridCountEntry" MinHeight="500" 
RowDetailsVisibilityChanged="GridCountEntry_OnRowDetailsVisibilityChanged" ItemsSource="{Binding CurrentRecord.StockTicketLines, Mode=TwoWay, UpdateSourceTrigger=PropertyChanged}" ShowGroupPanel="False" AutoGenerateColumns="False" CanUserFreezeColumns="False" RowDetailsVisibilityMode="Collapsed" >

       <!--        <telerik:RadGridView.ChildTableDefinitions>                <telerik:GridViewTableDefinition>                    <telerik:GridViewTableDefinition.Relation>                         <telerik:PropertyRelation ParentPropertyName="LineStockTransactions"></telerik:PropertyRelation>                    </telerik:GridViewTableDefinition.Relation>                </telerik:GridViewTableDefinition>            </telerik:RadGridView.ChildTableDefinitions>            -->      
<
telerik:RadGridView.Columns>        
<
telerik:GridViewDataColumn DataMemberBinding="{Binding LineProductCode}" Header="Code" IsReadOnly="True" Width="55"/>
       <telerik:GridViewDataColumn DataMemberBinding="{Binding LineRowAttribute}"  Header="Attribute" IsReadOnly="True" Width="70"/>
       <telerik:GridViewDataColumn DataMemberBinding="{Binding LineColumnAttribute}"  Header="Attribute" IsReadOnly="True" Width="70"/>  
      <
telerik:GridViewDataColumn DataMemberBinding="{Binding LineProductDescription}" Header="Description" IsReadOnly="True" Width="150"/>  
      <
telerik:GridViewDataColumn DataMemberBinding="{Binding LineStorageLocation}" Header="Storage Location" IsReadOnly="True" Width="130"/>   
     <
telerik:GridViewDataColumn DataMemberBinding="{Binding LineOwnerShip}" Header="Ownership" IsReadOnly="True" Width="100"/>    
    <
telerik:GridViewDataColumn DataMemberBinding="{Binding LineOnHand}" Header="On Hand" IsReadOnly="True" Width="70"/>    
    <
telerik:GridViewDataColumn DataMemberBinding="{Binding LineCounted}" Header="Counted"  Width="55"/>        <telerik:GridViewDataColumn DataMemberBinding="{Binding LineChange}" Header="Change" IsReadOnly="True"  Width="70"/>
     <telerik:GridViewToggleRowDetailsColumn />

     </telerik:RadGridView.Columns>  
      <
telerik:RadGridView.RowDetailsTemplate>
         <DataTemplate>
           <telerik:RadGridView ShowGroupPanel="False" AutoGenerateColumns="False" CanUserFreezeColumns="False" MinHeight="90" Margin="15,15,15,15">
         <telerik:RadGridView.Columns>
       <telerik:GridViewDataColumn DataMemberBinding="{Binding TransactionDate}" UniqueName="TransactionDate" Header="Trans Date" IsReadOnly="True" Width="70"/>
           <telerik:GridViewDataColumn DataMemberBinding="{Binding PerformedBy}" UniqueName="PerformedBy" Header="Who" IsReadOnly="True" Width="70"/>
             </telerik:RadGridView.Columns>
         </telerik:RadGridView>
         </DataTemplate>
       </telerik:RadGridView.RowDetailsTemplate>
   </telerik:RadGridView>


Rossen Hristov
Telerik team
 answered on 01 May 2013
3 answers
120 views
Any progress? In a post you where writing this.

Hi Branko,

Currently RadPropertyGrid does not support DataErrors validation (It supports exception validation only). However, as it is not a major feature we can implement it for you and include it in an internal build. I believe that we will manage to introduce this change in two weeks. I will keep in touch with you, in order to notify you as soon as the mentioned IB is available for download.

Regards,
Ivan Ivanov 
the Telerik team

and later on:

Posted on Feb 29, 2012 (permalink)

Hi Branko,

I will notify you as soon as the IB is released (it should be the next Monday/Tuesday). I will prepare a simple test project for your referense, as well. Please, do not hesitate to contact us if you have any further inquiries. 

Kind regards,
Ivan Ivanov 
the Telerik team

I need this badly, so please respond.. 

Posted on Feb 21, 2012 (permalink)

Hi Branko,

Currently RadPropertyGrid does not support DataErrors validation (It supports exception validation only). However, as it is not a major feature we can implement it for you and include it in an internal build. I believe that we will manage to introduce this change in two weeks. I will keep in touch with you, in order to notify you as soon as the mentioned IB is available for download.

Regards,
Ivan Ivanov 
the Telerik team

Posted on Feb 21, 2012 (permalink)

Hi Branko,

Currently RadPropertyGrid does not support DataErrors validation (It supports exception validation only). However, as it is not a major feature we can implement it for you and include it in an internal build. I believe that we will manage to introduce this change in two weeks. I will keep in touch with you, in order to notify you as soon as the mentioned IB is available for download.

Regards,
Ivan Ivanov 
the Telerik team

Posted on Feb 21, 2012 (permalink)

Hi Branko,

Currently RadPropertyGrid does not support DataErrors validation (It supports exception validation only). However, as it is not a major feature we can implement it for you and include it in an internal build. I believe that we will manage to introduce this change in two weeks. I will keep in touch with you, in order to notify you as soon as the mentioned IB is available for download.

Regards,
Ivan Ivanov 
the Telerik team

Posted on Feb 29, 2012 (permalink)

Hi Branko,

I will notify you as soon as the IB is released (it should be the next Monday/Tuesday). I will prepare a simple test project for your referense, as well. Please, do not hesitate to contact us if you have any further inquiries. 

Kind regards,
Ivan Ivanov 
the Telerik team

Posted on Feb 29, 2012 (permalink)

Hi Branko,

I will notify you as soon as the IB is released (it should be the next Monday/Tuesday). I will prepare a simple test project for your referense, as well. Please, do not hesitate to contact us if you have any further inquiries. 

Kind regards,
Ivan Ivanov 
the Telerik team
Ivan Ivanov
Telerik team
 answered on 01 May 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
Book
FileDialogs
ToolBar
ColorPicker
TimePicker
SyntaxEditor
MultiColumnComboBox
VirtualGrid
Wizard
ExpressionEditor
NavigationView (Hamburger Menu)
DesktopAlert
WatermarkTextBox
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
VirtualKeyboard
HighlightTextBlock
Security
TouchManager
StepProgressBar
Badge
OfficeNavigationBar
ExpressionParser
CircularProgressBar
SvgImage
PipsPager
SlideView
AI Coding Assistant
+? more
Top users last month
Rob
Top achievements
Rank 3
Bronze
Iron
Iron
Sergii
Top achievements
Rank 1
Iron
Iron
Dedalus
Top achievements
Rank 1
Iron
Iron
Lan
Top achievements
Rank 1
Iron
Doug
Top achievements
Rank 1
Want to show your ninja superpower to fellow developers?
Top users last month
Rob
Top achievements
Rank 3
Bronze
Iron
Iron
Sergii
Top achievements
Rank 1
Iron
Iron
Dedalus
Top achievements
Rank 1
Iron
Iron
Lan
Top achievements
Rank 1
Iron
Doug
Top achievements
Rank 1
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?