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

I have a docking with some tabPane. I dedock one, maximize it in a second monitor, dedock another one dock it to the other panel on the second screen, and when I undock one from the second screen, the panel is stretched out. Is there a way to fix this problem ?

Thank you,

Etienne
Nasko
Telerik team
 answered on 22 Apr 2015
1 answer
104 views

Working on a project where I have a cell template DataContext bound to the GridViewCell Value.

 <DataTemplate x:Key="DefaultCellTemplate">

 <StackPanel DataContext="{Binding Value, RelativeSource={RelativeSource FindAncestor, AncestorType={x:Type telerik:GridViewCell}}}">

                <TextBlock Text="{Binding PropertyValue, Mode=OneWay}"></TextBlock>
            </StackPanel>
 </DataTemplate>

<DataTemplate x:Key="DefaultCellEditTemplate">
            <StackPanel DataContext="{Binding Value, RelativeSource={RelativeSource FindAncestor, AncestorType={x:Type telerik:GridViewCell}}}">
                <TextBox Text="{Binding PropertyValue, Mode=TwoWay, UpdateSourceTrigger=PropertyChanged}"></TextBox>
            </StackPanel>
        </DataTemplate>

When entering values and tabbing through cells, when on the last cell and tab to move to first cell of the next column, I'm getting an app crash.  This seems to occur when virtualization is on and there are enough columns to cause the grid to scroll horizontally, and the UpdateSourceTrigger of the edit template is PropertyChanged.  Attached is a sample project that can reproduce the error.

Stefan
Telerik team
 answered on 22 Apr 2015
6 answers
910 views
Hi,

I have a ViewModel with a collection binded to my user control, and then one of the ViewModel properties is binded to a RadTreeView. I need to support multiple selection, but it seems I can't bind SelectedItems property. Any tips on how to achieve this?

Regards
Pavel R. Pavlov
Telerik team
 answered on 22 Apr 2015
1 answer
116 views

I have a RadTreeView with some Containers and some Items (the items do not contain other items). When I activate Drag and Drop everything works fine. My problem is that I have some Containers that should not work as drop target. Unfortunatly I could not find an example.

First I tried the property IsDroppingAllowed (I used it like IsExpanded and IsSelected). Unfortunatly the getter is never called.

Than I tried "OnDragOver"

DragDropManager.AddDragOverHandler(this.FolderRadTreeView, new Telerik.Windows.DragDrop.DragEventHandler(OnDragOver), true);

It seems that I have to set 
options.DropAction = DropAction.Move;

or

options.DropAction = DropAction.None;

and everything works fine. But after a while it drives me crazy. Is there anywhere a good example? Is there anywhere a checklist what I have to reimplement? 

I tried to use the DropTargetItem to check if the dropping is allowed.

var options = DragDropPayloadManager.GetDataFromObject(e.Data, TreeViewDragDropOptions.Key) as TreeViewDragDropOptions;
var dropItem = options.DropTargetItem.Item;
(dropItem as IFolderItem).IsDroppable(options.DraggedItems));

If I drop inside everthing is fine. If I drop before (Telerik.Windows.Controls.DropPosition.
Before) it seems that my dropItem I used for IsDroppable() is not the container where the RadTreeView drops my item. 

An other trapdoor it that I have to check that I do not drag an Item in itself (drag A and drop it in A or drop in a child of A).

Martin Ivanov
Telerik team
 answered on 22 Apr 2015
4 answers
86 views

Hi team,

I am using custom Connectors and Connections along with MVVM. Per the thread, I can add some custom connection points in the overridden method GetConnectionContainerForItemOverride

protected override IConnection GetConnectionContainerForItemOverride(object item)
{
    if (item is Link)
    {
        ...

                return a custom connection object;

    }
 
    return null;
}

Meanwhile I want to attach the connection to my custom connectors inside this method. However, at this time, the connectors of the shape still are the 5 default connectors. Are there any means to control the sequence of the overwritten methods? Or I should overwrite another virtual method? 

Thanks,

Jingfei

Jackey
Top achievements
Rank 1
 answered on 22 Apr 2015
5 answers
215 views

There is a bug in RadListBox when using GroupStyle. When I select any an item from second group, radlistbox scrolls to first item in second group. This makes double click on an items almost imposible.

I wrote a simple sample demonstrating the behaviour with comparison to regular listbox

<Window x:Class="RadControlsWpfApp2.MainWindow"
  xmlns:local="clr-namespace:RadControlsWpfApp2"
  Title="MainWindow" Height="350" Width="525">
  <Window.DataContext>
    <local:MainWindowVM />
  </Window.DataContext>
  <Grid>
 
    <StackPanel Orientation="Horizontal">
      <ListBox x:Name="listbox" ItemsSource="{Binding CollectionView}" IsSynchronizedWithCurrentItem="False" DisplayMemberPath="Name" FontSize="20" MinWidth="150">
        <ListBox.GroupStyle>
          <GroupStyle  />
        </ListBox.GroupStyle>
      </ListBox>
 
 
 
      <telerik:RadListBox x:Name="radlistbox" ItemsSource="{Binding CollectionView}"  DisplayMemberPath="Name" FontSize="20" MinWidth="150" Margin="20,0,0,0">
        <telerik:RadListBox.GroupStyle>
          <GroupStyle  />
        </telerik:RadListBox.GroupStyle>
      </telerik:RadListBox>
    </StackPanel>
  </Grid>
</Window>

using System.Collections.Generic;
using System.Windows.Data;
 
namespace RadControlsWpfApp2
{
  public class MainWindowVM
  {
    public List<ItemVM> Collection { get; set; }
 
    public ListCollectionView CollectionView    {      get;      set;    }
 
    public MainWindowVM()
    {
      Collection = new List<ItemVM>
      {
        new ItemVM { Group = "A", Name = "Item 1" },
        new ItemVM { Group = "A", Name = "Item 2" },
        new ItemVM { Group = "A", Name = "Item 3" },
        new ItemVM { Group = "A", Name = "Item 4" },
        new ItemVM { Group = "A", Name = "Item 5" },
        new ItemVM { Group = "A", Name = "Item 6" },
        new ItemVM { Group = "B", Name = "Item 1" },
        new ItemVM { Group = "B", Name = "Item 2" },
        new ItemVM { Group = "B", Name = "Item 3" },
        new ItemVM { Group = "B", Name = "Click Here!" },
        new ItemVM { Group = "B", Name = "Item 5" },
        new ItemVM { Group = "B", Name = "Item 6" },
      };
 
      var view = new ListCollectionView(Collection);
      view.GroupDescriptions.Add(new PropertyGroupDescription("Group"));
      CollectionView = view;
    }
 
 
  }
 
  public class ItemVM
  {
    public string Group { get; set; }
    public string Name { get; set; }
  }
}


Nasko
Telerik team
 answered on 21 Apr 2015
8 answers
198 views
Hi Team - Is it possible to have paging or load on demand feature with RadAutoCompleteBox control? I have thousands of records to show in an autocompletebox which takes a lot of time to load.
Vitalij
Top achievements
Rank 1
 answered on 21 Apr 2015
6 answers
294 views

Hello,

I have a custom control which inherits from usercontrol. My control is the itemtemplate of a radtreeview.

<telerik:RadTreeView.ItemTemplate>

    <HierarchicalDataTemplate ItemsSource="{Binding MyList}">

         <MyControls:MyTreeNode AllowDrop="{Binding IsDropAllowed}"/>

    </HierarchicalDataTemplate>

</telerik:RadTreeView.ItemTemplate>

 

I want to bind the AllowDrop Property from my control (MyTreeNode). When AllowDrop is false, it should not possible to drop other nodes on this node. But this doesn’t work. The radtreeview ignores the allocation. Is there any way that my control has the same behavior likes a radtreeviewitem, when the IsDropAllowed Property is false.


With best regards,
Sico

Petar Mladenov
Telerik team
 answered on 21 Apr 2015
2 answers
102 views
Hello,

  When RibbonWindow set MinWidth or MinHeight,
  if width or height to be smaller than MinWidth or MinHeight,
  it's clipping the window, but previous version is ok.

  The simple example :

  <Grid>
      <Button VerticalAlignment="Center" Height="100" Background="Yellow">Test</Button>
  </Grid>

  public partial class MainWindow : RadRibbonWindow
  {
      public MainWindow()
      {
          InitializeComponent();

          this.MinWidth = 500;
      }
  }

  2015 Q1 is OK
  2015 Q1 Hotfix 0316 is OK
  2015 Q1 Hotfix 0323 is clip
  2015 Q1 SP1 is clip
  2015 Q1 SP1 Hotfix 0406 is clip
  2015 Q1 SP1 Hotfix 0413 is clip

  How can I fix this ? Thanks.

Regards

Chang
Top achievements
Rank 1
 answered on 21 Apr 2015
5 answers
140 views

Hi, I want the time bar to show hours in European format (e.g 23 and not 11 PM).

The only way I found to achieve this is to set the global Telerik.Windows.Controls.LocalizationManager.DefaultCulture.

  1. 1. I tried to set Telerik.Windows.Controls.LocalizationManager.DefaultCulture to "de-DE". It removes AM/PM but does not change the number. So the range I get is 1-12 and not 0-23
  2. In our application we use a custom culture info, something like this
    cultureInfo = new CultureInfo("en-US");
    cultureInfo.NumberFormat = ...
    cultureInfo.DateTimeFormat.ShortDatePattern = ...

    What part of the cultureInfo is used to determine how hours are shown in time bar?
  3. I have similar issue with datetimepicker. How can i modify our culture info such that is uses 0-23 for hours instead of AM/PM (I see it has a property culture, so here I can just set "de-DE" as a workaround without effecting rest of application)
Milena
Telerik team
 answered on 21 Apr 2015
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
Security
VirtualKeyboard
HighlightTextBlock
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?