Telerik Forums
UI for WPF Forum
5 answers
349 views
 Lets say, i have 70 records, and currently in view is 18 records. Now, I am pressing tab for 19th time then scroll down to display 19th record. Scroll according to tab key navigation.
Please see attachment
Yoan
Telerik team
 answered on 06 Dec 2016
2 answers
291 views
Hello folks!


How can I add DockingPanesFactory to the RadDocking dynamically?

 <telerik:RadDocking 
                            x:Name="Docking"
                            >
            <telerik:RadDocking.DockingPanesFactory>
                <local:CustomDockingPanesFactory />
            </telerik:RadDocking.DockingPanesFactory>
   </telerik:RadDocking>

 var Dock = new Telerik.Windows.Controls.RadDocking();
.....
Any advise or suggestion will be greatly appreciated.

hokushin
Top achievements
Rank 1
 answered on 06 Dec 2016
1 answer
337 views
Hi, I try use RadChartView to display finance data with Candle-style series. After setup data, I set horizontal zoom, but vertical zoom remains unchanged (see screenshot). How to make radchartview auto-Y-scale  for visible part of chart?
Martin Ivanov
Telerik team
 answered on 06 Dec 2016
1 answer
727 views

Hello,

I am looking a generic solution to import excel to radgridview.

I want to do this at my control(not viewmodel or codebehind,I custimized radgridview)

Is there a way to do that

Lance | Senior Manager - Technical Support
Telerik team
 answered on 05 Dec 2016
1 answer
234 views

Hello!

      I'm using the "RadRichTextBox" in my project. I'm facing a problem when the control is disabled (i.e. IsEnabled = False). In disabled state the controls turns Grey and the text visibility is very low. I cannot use read-only or any other property as they are being used for other purpose. I need to change the template for Disabled control, so as to not make it Grey but make the Disable mask transparent instead. Need help for the same.

Thanks

Tushar

     

Lance | Senior Manager - Technical Support
Telerik team
 answered on 05 Dec 2016
3 answers
756 views

I am replacing a TreeView control with a RadTreeView control however I have run in to a issue. I want the user to be able to click on the body of the TreeView (instead of a node) and have it deselect the item in the tree view.

 

With the original TreeView I would do

<TreeView Grid.Row="0" MouseDown="TreeView_OnMouseDown">
    <TreeViewItem Header="Item 1"/>
    <TreeViewItem Header="Item 2"/>
</TreeView>

Then in the code behind I would have

private void TreeView_OnMouseDown(object sender, MouseButtonEventArgs e)
{
    var treeView = (TreeView)sender;
    var items = treeView.Items.Cast<TreeViewItem>();
    foreach (var treeViewItem in items)
    {
        treeViewItem.IsSelected = false;
    }
     
}

 

And this would work correctly. However if I do

<telerik:RadTreeView Grid.Row="1" MouseDown="RadTreeView_OnMouseDown">
    <telerik:RadTreeViewItem Header="Item 3"/>
    <telerik:RadTreeViewItem Header="Item 4"/>
</telerik:RadTreeView>

and

private void RadTreeView_OnMouseDown(object sender, MouseButtonEventArgs e)
{
    var treeView = (RadTreeView)sender;
    treeView.SelectedItem = null;
    MessageBox.Show("RadTreeView_OnMouseDown fired!");
}

the OnMouseDown event never fires.

Looking at the OnMouseDown event with Snoop it appears to be getting marked as handled by the ScrollViewer inside the RadListView.

What is the correct way to deselect the node when clicking on the body of the tree view? Attached is a simple example program that shows the two controls side by side with their different behaviors.

Scott
Top achievements
Rank 1
 answered on 05 Dec 2016
3 answers
318 views

Hi,

At the moment I'm facing an issue, I have a RadGridView which can show different tables with different definitions(not at the same time)
So AutoGenerateColumns is set to True.

now it can happen that some columns have an FK to another table.
Before I replaced those columns in the DataLoaded event but because of performance reasons I would like to do those replaces in the CurrentCellChanged event.

The problem when I do this is that the new GridViewComboBoxColumn misses the link to the actual datasource, and while reading the value for saving in the database, the value is DBNULL.

the gridview in de Xaml looks like this

<DataTemplate x:Key="AdminViewMainSectorTemplate">
        <Grid Margin="10">
            <Grid>
                <telerik:RadBusyIndicator x:Name="BusyIndicator" Grid.Row="2" >
                    <telerik:RadGridView x:Name="gridViewAdminData"
                                                     ItemsSource="{Binding DataRecords, Mode=TwoWay}"
                                         RowEditEnded="EditRecord"
                                         Deleted="deleteRecord"
                                         AddingNewDataItem="AddingNewDataItem"
                                         MinColumnWidth="100"
                                         ColumnWidth="*"
                                         NewRowPosition="Top"                                         
                                         AutoGeneratingColumn="AutoGeneratingColumn"
                                         DataLoading="LoadData"
                                         DataLoaded="DataLoaded"
                                         CurrentCellChanged="CurrentCellChanged"
                                         SelectionUnit="Cell"
                                         >
                        <!--DataLoading="LoadData"
                                         DataLoaded="DataLoaded"-->
                        <telerik:EventToCommandBehavior.EventBindings>
                            <telerik:EventBinding
                            Command="{Binding HandleAddingNewRecordToDevicesGridCommand}"
                            EventName="AddingNewDataItem"
                            PassEventArgsToCommand="True"/>
                        </telerik:EventToCommandBehavior.EventBindings>
                    </telerik:RadGridView>
                </telerik:RadBusyIndicator>
            </Grid>
        </Grid>
    </DataTemplate>

and my code behind looks like this:

private void CurrentCellChanged(object sender, GridViewCurrentCellChangedEventArgs e)
       {
           RadGridView rgv = (RadGridView)sender;
           GridViewCell cell = rgv.CurrentCell;
           if (cell != null && typeof(GridViewDataColumn) == cell.Column.GetType())
           {
               Models.MyEntities db = new Models.MyEntities();
               string tableName = Helpers.GlobalParameters.currenTableName;
               if (tableName =="batches")
               {
                   string fieldname = cell.Column.UniqueName;
                   if (fieldname == "ProductieOrderId")
                   {
                       int index = cell.Column.DisplayIndex;
                       GridViewComboBoxColumn cbb = new GridViewComboBoxColumn();
                       cbb.DataMemberBinding = new System.Windows.Data.Binding(fieldname);
                       //cbb.DataMemberBinding = cell.DataColumn.DataMemberBinding;
                       cbb.ItemsSource = db.productieorder.ToList();
                       cbb.SelectedValueMemberPath = fieldname;
                       cbb.DisplayMemberPath = "Id";
                       //cbb.Name = fieldname;
                       cbb.UniqueName = fieldname;
                       cbb.DisplayIndex = index;
                       rgv.Columns.Remove(cell.Column);
                       //rgv.Columns.Remove(cell.DataColumn);
                       rgv.Columns.Add(cbb);
 
                   }
               } else if (tableName =="artikel")

where the Field "Id" is the related field on the related table
If I do this
cbb.SelectedValueMemberPath = "Id";

what I would say is logical, the shown value in the combobox stays empty.

does anyone know where to look to fix this issue?

Martin
Telerik team
 answered on 05 Dec 2016
1 answer
300 views

Hi,

I am using a DataTemplateSelector and DataTemplates to show and interact with Custom Appointments in the schedule.

The Custom Appointment has a field called BindingItem added which holds a reference to my data.I then have checkboxes and drop down boxes that bind to fields within the BindingItem.

Everything works great until I refresh the entire appointments collection.

It seems like DataTemplates are being reused (by the container?) and any interaction seems to be with the old BindingItem not the new one, even though the appointment collection is brand new and each appointment has a new BindingItem set.

I can get this resolved in 2 ways, the first is to scroll the offending appointments off the screen and back again which must be forcing some kind of container refresh. Not very useful for end users.

The second is to use the following code to force a container refresh, note that AddIdleAction adds the code onto the dispatcher at application idle priority:

        private void RefreshAppointmentBindingItem(CustomAppointment appt)
        {
            if (appt != null)
            {
                object item = appt.BindingItem;

                AddIdleAction(() =>
                {
                    appt.BindingItem = null;
                });

                AddIdleAction(() =>
                {
                    appt.BindingItem = item;
                });
            }
        }

Both ways are messy, do you have any better suggestions?

Thanks

Anthony

Stefan
Telerik team
 answered on 05 Dec 2016
6 answers
219 views
I have an RTF document that is made up of many smaller RTF documents merged together.  The document that I am using for testing contains over 1100 pages. Printing this document setting the Document property of a RadRichTextBox and calling the print method is very slow.  I can open the same document in Word and it prints about 10 times faster.  Are there any recommendations for improving printing performance?  Thanks.
tushar
Top achievements
Rank 1
 answered on 05 Dec 2016
1 answer
135 views

Basically, when the use hits the OK button in the raddataform for a particular row I want to collapse the details.

An Mvvm friendly solution would be great!

Thanks ... Ed

 

Dilyan Traykov
Telerik team
 answered on 05 Dec 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
DataPager
PersistenceFramework
Styling
TimeBar
OutlookBar
TransitionControl
FileDialogs
Book
ToolBar
ColorPicker
TimePicker
MultiColumnComboBox
SyntaxEditor
VirtualGrid
NavigationView (Hamburger Menu)
Wizard
ExpressionEditor
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
Callout
PasswordBox
SplashScreen
Localization
Rating
Accessibility
CollectionNavigator
AutoSuggestBox
Security
VirtualKeyboard
HighlightTextBlock
TouchManager
StepProgressBar
Badge
OfficeNavigationBar
ExpressionParser
CircularProgressBar
SvgImage
PipsPager
SlideView
AI Coding Assistant
InlineAIAssistant
+? more
Top users last month
Grant
Top achievements
Rank 3
Iron
Iron
Iron
Dean
Top achievements
Rank 1
Leland
Top achievements
Rank 2
Iron
Iron
Iron
Emil
Top achievements
Rank 1
Iron
Robert
Top achievements
Rank 1
Want to show your ninja superpower to fellow developers?
Top users last month
Grant
Top achievements
Rank 3
Iron
Iron
Iron
Dean
Top achievements
Rank 1
Leland
Top achievements
Rank 2
Iron
Iron
Iron
Emil
Top achievements
Rank 1
Iron
Robert
Top achievements
Rank 1
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?