Telerik Forums
UI for WPF Forum
3 answers
127 views
I need to create a custom text editor, which will be editing device specific files.  The files are text files and supposed to contain a subset of the low ASCII characters.   Some of the characters should display as strings rather than as their normal display value in the loaded windows character set.  I need to display tab characters in their expanded representation as spaces.  The files use Form Feeds (x0C) to mark pages.  These need to be represented on their own line as a string of dashes.     Can this type of character rendering control be accomplished with the RichTextBox control and it's txtformatproviders?   If so what would be involved (or is there an example in the SDK's I should look at? 

Tanya
Telerik team
 answered on 18 Feb 2015
2 answers
213 views
Hi Support,

I want to increase the height and width of the Rad Data Pager's buttons and the TextBlock. As it is very small in sizing. As I am trying to give some custom style but still I do not know how to increase its Height. Please help me.

Have a look into the attached screen-shot.

Thanks
Rahul
Rahul
Top achievements
Rank 1
 answered on 18 Feb 2015
6 answers
832 views
Hi, I have been searching the web to find an answer and I didn't found anything.

I want to group my itemsource by GroupName inside the GridViewComboBoxColumn but I don't seem to find a way to do it.
I achieve grouping via GroupStyle with a simple ComboBox.

See attached png.

Also, if I want to filter GridViewComboBoxColumn when I add an itemTemplate to display 2 value, how can I filter it?


Guillaume
Top achievements
Rank 1
 answered on 18 Feb 2015
11 answers
744 views
We're having problems with a Delete button that we've added as a column in a GridView.  We're using a CommandBinding, but the DeleteExecuted function where we remove the item from the collection doesn't get called, yet the row automagically disappears from the GridView.  I can be debugging for a while trying to delete a bunch of rows (one-at-a-time) without ever hitting a breakpoint set at the very top of the DeleteExecuted function.  During this time the rows are consistently being removed from the GridView - but the DeleteExecuted function isn't called.  It's as if something within the GridView is automagically removing the row and then setting the event as handled and not routing on to the bound command.  Then out of the blue during the same debugging session it will *sometimes* hit my breakpoint, and work reliably from that point on.  Incredibly frustrating. 

For the record, I'm using the new RadControls for WPF 2010 Q1 release build, running VS 2008 and .NET 3.5.  Updating to VS 2010 and .NET 4 is not an option for us at this time.  I'm about 90% sure that this was working reliably before we upgraded to the 2010 Q1 release, but unfortunately rolling back isn't an attractive option because we needed a fix that became available in the 2010 Q1 release.

I'm hoping someone out there can throw me some bread crumbs on what might be going on and how to fix it.

Here's where we define the button for the delete column:
<telerik:GridViewColumn Header="Delete" IsVisible="True">  
    <telerik:GridViewColumn.CellTemplate> 
        <DataTemplate> 
            <Button Width="18" Height="18" Margin="5,0"   
                    Command="ApplicationCommands.Delete" CommandParameter="{Binding}" > 
                <Button.Content> 
                    <Grid Width="8.083" Height="8.664" VerticalAlignment="Center" HorizontalAlignment="Center">  
                        <Path Fill="{x:Null}" Stretch="Fill" Stroke="#FF000000" Margin="0.083,0.664,0,0" Data="M0.50001547,0.5 L6.5000797,6.5000169 M6.5000155,0.5 L0.5,6.5000704" StrokeThickness="2"/>  
                        <Path Fill="#FFCE3527" Stretch="Fill" Stroke="#FFCD3527" Margin="0,0,0.083,0.664" Data="M0.50001547,0.5 L6.5000797,6.5000169 M6.5000155,0.5 L0.5,6.5000704" StrokeThickness="2"/>  
                    </Grid> 
                </Button.Content> 
            </Button> 
        </DataTemplate> 
    </telerik:GridViewColumn.CellTemplate> 
</telerik:GridViewColumn> 
 

And the pertinent stuff from the code-behind:

public ucChartRegionGrid2()  
{  
    InitializeComponent();  
 
    this.Loaded += new RoutedEventHandler( ucChartRegionGrid2_Loaded );  
    this.CommandBindings.Add( new CommandBinding( ApplicationCommands.Delete,   
                                this.DeleteExecuted, this.DeleteCanExecute ) );  
    radGridViewDataBinding.SelectionChanged += new   
        EventHandler<Telerik.Windows.Controls.SelectionChangeEventArgs>(radGridViewDataBinding_SelectionChanged);  
}  
 
public void DeleteCanExecute(object sender, CanExecuteRoutedEventArgs e)  
{  
    e.CanExecute = true;  
}  
 
public void DeleteExecuted(object sender, ExecutedRoutedEventArgs e)  
{  
    // set a breakpoint here.  It’s not hit, but the row disappears from the grid!?  
    RegionEvent2 deleteRange = e.Parameter as RegionEvent2;  
 
 


Thanks in advance!
Maya
Telerik team
 answered on 18 Feb 2015
1 answer
133 views
Hello,

Is there any support in the RadMap for wrapping around a map, so that we can implement continuously scrolling the map as if we are spinning a globe? Something along the lines of https://developers.arcgis.com/android/guide/enable-wrap-around.htm ?

If there is no inbuilt support how would you suggest we approach adding this functionality ourselves? We are using UriImageProvider, TMSProvider, OpenStreetMapProvider and ArcGISMapProvider.

The only telerik support I can find on this matter was a forum thread from four years ago, where it was mentioned that the functionality was planned http://www.telerik.com/forums/international-dateline-support

Many Thanks


Pavel R. Pavlov
Telerik team
 answered on 18 Feb 2015
5 answers
305 views
My scenario:
I have a simple Telerik GridView and a single Textbox in my WPF App. When I type in the TextBox (FilterBox), I update some FilterDescriptor values and the GridView gets filtered accordingly. 

What I want to achieve:
Basically the same behaviour as the Google Chrome Browser in "Search-Mode"; The FilterBox receives all Keyboard presses EXCEPT the arrow keys and "Page Up", "Page Down". Those button presses should be redirected to the GridView, allowing the users to scroll through the filtered results while keeping the focus on the FilterBox (and so allow them to adjust the filter text until they are satisfied with the results). 

I've tried handling the PreviewKeyDown event of the FilterBox in the following way:

private void textFilter_PreviewKeyDown(object sender, KeyEventArgs e)
   {
     switch (e.Key)
     {
       case Key.Down:
         {
           e.Handled = true;
           RoutedUICommand moveDownCommand = RadGridViewCommands.MoveDown as RoutedUICommand;
           RoutedUICommand selectCommand = RadGridViewCommands.SelectCurrentUnit as RoutedUICommand;
           moveDownCommand.Execute(null, this.radGridView);
           selectCommand.Execute(null, this.radGridView);
           break;
         }
       case Key.Up:
         {
           e.Handled = true;
           RoutedUICommand moveUpCommand = RadGridViewCommands.MoveUp as RoutedUICommand;
           RoutedUICommand selectCommand = RadGridViewCommands.SelectCurrentUnit as RoutedUICommand;
           moveUpCommand.Execute(null, this.radGridView);
           selectCommand.Execute(null, this.radGridView);
           break;
         }
       default:
         return;
     }
     textFilter.Focus();
    }
The code works (the up and down arrow keys control the grid), but the FilterBox loses the focus. 

What do I have to do?
Dimitrina
Telerik team
 answered on 18 Feb 2015
1 answer
105 views
I'm using a NumericIndicator on a RadialGauge with GaugeRange values. I'd like to set the NumericIndicator to use the GaugeRange values as the foreground color  when using FontNumberPosition for the NumericIndicator.Position values. I've set the NumericIndicator UseRangeColor =True but according to the documentation, that sets the background color. Is there a quick way to achieve the result I'm looking for?
Bart
Top achievements
Rank 1
 answered on 17 Feb 2015
6 answers
256 views
I have very very plain test application with HtmlDataProvider and RadRichTextBox only. When I start the application RichTextBox area has small gray square in the corner (screen.png). I think this is a bug associated with HtmlDataProvider and html code which produce HtmlDataProvider.

MainWindow.xaml
<Window x:Class="TestTelerikWpfApp.MainWindow"
        xmlns:local="clr-namespace:TestTelerikWpfApp"
        Title="MainWindow" Height="300">
    <Window.Resources>
    </Window.Resources>
    <Grid>
        <telerik:HtmlDataProvider RichTextBox="{Binding ElementName=richTextBox}"
                                  Html="{Binding Path=Notes, Mode=TwoWay}" />
        <telerik:RadRichTextBox Name="richTextBox" Width="800" Height="600" />
 
    </Grid>
</Window>

MainWindow.xaml.cs
using System;
using System.Collections.Generic;
using System.Linq;
using System.Windows;
using System.Windows.Data;
using Telerik.Windows.Controls;
 
namespace TestTelerikWpfApp
{
    /// <summary>
    /// Interaction logic for MainWindow.xaml
    /// </summary>
    public partial class MainWindow : Window
    {
        public MainWindow()
        {
            InitializeComponent();
 
            DataContext = new ViewModel();
        }
    }
}

ViewModel.cs
using System;
using Telerik.Windows.Controls;
 
namespace TestTelerikWpfApp
{
    public class ViewModel : ViewModelBase
    {
        private String notes;
        public String Notes
        {
            get
            {
                if (null == notes)
                {
                    Notes = String.Empty;
                }
                return this.notes;
            }
            set
            {
                if (value != this.notes)
                {
                    this.notes = value;
                    OnPropertyChanged(() => this.Notes);
                }
            }
        }
    }
}
Igor
Top achievements
Rank 1
 answered on 17 Feb 2015
1 answer
217 views
Hi,
  I've got a problem with the new RadialMenu. I'm trying to using it into a Grid object and open it with the option PopupPlacement="MousePoint".
   <Grid x:Name="myGrid">
        <telerik:RadRadialMenu.RadialContextMenu>
            <telerik:RadRadialMenu PopupPlacement="MousePoint" IsOpen="True" StaysOpenOnShow="True">
                <telerik:RadRadialMenuItem>
                    <telerik:RadRadialMenuItem Header="Refresh" CommandParameter="REFRESH" />
                    <telerik:RadRadialMenuItem Header="Search" CommandParameter="SEARCH" ContentSectorBackground="LightBlue" />
                </telerik:RadRadialMenuItem>
            </telerik:RadRadialMenu>
        </telerik:RadRadialMenu.RadialContextMenu>
        <Image Source="landscape.jpg" />
    </Grid>
I've used the same algorithm used in the Demo for showing / hiding the ContextMenu:

private void OnEditorMouseUp(object sender, System.Windows.Input.MouseButtonEventArgs e)
        {
            if (e.ClickCount == 1)
            {
                var radialMenu = RadRadialMenu.GetRadialContextMenu(this.Editor);
                var mousePoint = e.GetPosition(this.Editor as IInputElement);
                radialMenu.PopupHorizontalOffset = mousePoint.X;
                radialMenu.PopupVerticalOffset = mousePoint.Y;
                RadialMenuCommands.Show.Execute(null, this.Editor);
            }
        }

private void OnEditorMouseDown(object sender, MouseButtonEventArgs e)
        {
            if (e.ClickCount == 1)
            {
                RadialMenuCommands.Hide.Execute(null, sender as IInputElement);
            }
        }
For the first click everything is working fine and the RadialContextMenu is shown exactly centered with the Mouse Pointer but... after the second click the RadialContextMenu popup as it was PopupPlacement="Mouse".

Is it a bug ?


Thanks for the help



Kalin
Telerik team
 answered on 17 Feb 2015
1 answer
155 views
I've implemented Drag & Drop into a RadGridView. The DataObject I'm dropping is a string.

I need to detect whether the string is dropped into a Cell (in which case it will add the string to the cell value) or elsewhere on the RadGridView (where a new row will be created).

private void OnDropAttributes(object sender, Telerik.Windows.DragDrop.DragEventArgs args)
        {
            DataObject data = (args.Data as DataObject);

            ...?
Nick
Telerik team
 answered on 17 Feb 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
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?