Telerik Forums
UI for WPF Forum
1 answer
87 views

 I have RadDocument which is having some html input.

var provider = new HtmlFormatProvider();
RadDocument _document = provider.Import(some xml text input);

Now I am assigning this _document to the RichTextBox Document.

RichTextBox1.Document = _document ;

While rendering this RichTextBox in UI we are getting the below Exception.

The component 'Telerik.Windows.Documents.UI.Layers.TableDecorationLayers.TableMovement.TableAdorner' does not have a resource identified by the URI '/Telerik.Windows.Documents;component/ui/layers/tabledecorationlayers/tablemovement/tableadorner.xaml'

 And StackTrace is:





at System.Windows.Application.LoadComponent(Object component, Uri resourceLocator)
at Telerik.Windows.Documents.UI.Layers.TableDecorationLayers.TableMovement.TableAdorner..ctor(DocumentWebLayoutPresenter webPresenter, UILayerUpdateContext context, TableMovementUILayer movementLayer)
at Telerik.Windows.Documents.UI.Layers.TableDecorationLayers.TableMovement.TableMovementUILayer.InitializeAdorner()
at Telerik.Windows.Documents.UI.Layers.TableDecorationLayers.TableMovement.TableMovementUILayer.UpdateViewPortOverride(UILayerUpdateContext context)
at Telerik.Windows.Documents.UI.Layers.UIElementsLayer.UpdateViewPort(UILayerUpdateContext context)
at Telerik.Windows.Documents.UI.DocumentWebLayoutPresenter.UpdateUILayersViewPortSize(RectangleF viewPort)
at Telerik.Windows.Documents.UI.DocumentWebLayoutPresenter.MeasureOverride(Size availableSize)
at System.Windows.FrameworkElement.MeasureCore(Size availableSize)
at System.Windows.UIElement.Measure(Size availableSize)
at MS.Internal.Helper.MeasureElementWithSingleChild(UIElement element, Size constraint)
at System.Windows.Controls.ContentPresenter.MeasureOverride(Size constraint)
at System.Windows.FrameworkElement.MeasureCore(Size availableSize)
at System.Windows.UIElement.Measure(Size availableSize)
at System.Windows.Controls.Control.MeasureOverride(Size constraint)
at System.Windows.FrameworkElement.MeasureCore(Size availableSize)
at System.Windows.UIElement.Measure(Size availableSize)
at System.Windows.Controls.Grid.MeasureCell(Int32 cell, Boolean forceInfinityV)
at System.Windows.Controls.Grid.MeasureCellsGroup(Int32 cellsHead, Size referenceSize, Boolean ignoreDesiredSizeU, Boolean forceInfinityV, Boolean& hasDesiredSizeUChanged)
at System.Windows.Controls.Grid.MeasureCellsGroup(Int32 cellsHead, Size referenceSize, Boolean ignoreDesiredSizeU, Boolean forceInfinityV)
at System.Windows.Controls.Grid.MeasureOverride(Size constraint)
at System.Windows.FrameworkElement.MeasureCore(Size availableSize)
at System.Windows.UIElement.Measure(Size availableSize)
at System.Windows.Controls.Border.MeasureOverride(Size constraint)
at System.Windows.FrameworkElement.MeasureCore(Size availableSize)
at System.Windows.UIElement.Measure(Size availableSize)
at System.Windows.Controls.Grid.MeasureOverride(Size constraint)
at System.Windows.FrameworkElement.MeasureCore(Size availableSize)
at System.Windows.UIElement.Measure(Size availableSize)
at System.Windows.Controls.Control.MeasureOverride(Size constraint)
at System.Windows.FrameworkElement.MeasureCore(Size availableSize)
at System.Windows.UIElement.Measure(Size availableSize)
at System.Windows.Controls.StackPanel.StackMeasureHelper(IStackMeasure measureElement, IStackMeasureScrollData scrollData, Size constraint)
at System.Windows.Controls.StackPanel.MeasureOverride(Size constraint)
at System.Windows.FrameworkElement.MeasureCore(Size availableSize)
at System.Windows.UIElement.Measure(Size availableSize)
at MS.Internal.Helper.MeasureElementWithSingleChild(UIElement element, Size constraint)
at System.Windows.Controls.ScrollContentPresenter.MeasureOverride(Size constraint)
at System.Windows.FrameworkElement.MeasureCore(Size availableSize)
at System.Windows.UIElement.Measure(Size availableSize)
at System.Windows.Controls.Grid.MeasureCell(Int32 cell, Boolean forceInfinityV)
at System.Windows.Controls.Grid.MeasureCellsGroup(Int32 cellsHead, Size referenceSize, Boolean ignoreDesiredSizeU, Boolean forceInfinityV, Boolean& hasDesiredSizeUChanged)
at System.Windows.Controls.Grid.MeasureCellsGroup(Int32 cellsHead, Size referenceSize, Boolean ignoreDesiredSizeU, Boolean forceInfinityV)
at System.Windows.Controls.Grid.MeasureOverride(Size constraint)
at System.Windows.FrameworkElement.MeasureCore(Size availableSize)
at System.Windows.UIElement.Measure(Size availableSize)
at System.Windows.Controls.Border.MeasureOverride(Size constraint)
at System.Windows.FrameworkElement.MeasureCore(Size availableSize)
at System.Windows.UIElement.Measure(Size availableSize)
at System.Windows.Controls.ScrollViewer.MeasureOverride(Size constraint)
at System.Windows.FrameworkElement.MeasureCore(Size availableSize)
at System.Windows.UIElement.Measure(Size availableSize)
at System.Windows.Controls.Grid.MeasureOverride(Size constraint)
at System.Windows.FrameworkElement.MeasureCore(Size availableSize)
at System.Windows.UIElement.Measure(Size availableSize)
at System.Windows.Controls.Border.MeasureOverride(Size constraint)
at System.Windows.FrameworkElement.MeasureCore(Size availableSize)
at System.Windows.UIElement.Measure(Size availableSize)
at System.Windows.Controls.Grid.MeasureCell(Int32 cell, Boolean forceInfinityV)
at System.Windows.Controls.Grid.MeasureCellsGroup(Int32 cellsHead, Size referenceSize, Boolean ignoreDesiredSizeU, Boolean forceInfinityV, Boolean& hasDesiredSizeUChanged)
at System.Windows.Controls.Grid.MeasureCellsGroup(Int32 cellsHead, Size referenceSize, Boolean ignoreDesiredSizeU, Boolean forceInfinityV)
at System.Windows.Controls.Grid.MeasureOverride(Size constraint)
at System.Windows.FrameworkElement.MeasureCore(Size availableSize)
at System.Windows.UIElement.Measure(Size availableSize)
at System.Windows.Controls.Border.MeasureOverride(Size constraint)
at System.Windows.FrameworkElement.MeasureCore(Size availableSize)
at System.Windows.UIElement.Measure(Size availableSize)
at MS.Internal.Helper.MeasureElementWithSingleChild(UIElement element, Size constraint)
at System.Windows.Controls.ContentPresenter.MeasureOverride(Size constraint)
at System.Windows.FrameworkElement.MeasureCore(Size availableSize)
at System.Windows.UIElement.Measure(Size availableSize)
at System.Windows.Controls.Grid.MeasureOverride(Size constraint)
at System.Windows.FrameworkElement.MeasureCore(Size availableSize)
at System.Windows.UIElement.Measure(Size availableSize)
at System.Windows.ContextLayoutManager.UpdateLayout()
at System.Windows.ContextLayoutManager.UpdateLayoutCallback(Object arg)
at System.Windows.Media.MediaContext.FireInvokeOnRenderCallbacks()
at System.Windows.Media.MediaContext.RenderMessageHandlerCore(Object resizedCompositionTarget)
at System.Windows.Media.MediaContext.AnimatedRenderMessageHandler(Object resizedCompositionTarget)
at System.Windows.Threading.ExceptionWrapper.InternalRealCall(Delegate callback, Object args, Int32 numArgs)
at MS.Internal.Threading.ExceptionFilterHelper.TryCatchWhen(Object source, Delegate method, Object args, Int32 numArgs, Delegate catchHandler) 

 

Please help me to resolve this issue.


 

Petya
Telerik team
 answered on 29 Jun 2015
5 answers
500 views
When using KeyboardNavigation.IsTabStop="true" in a RadMaskedInput textbox, you cannot shift-tab out of the control.
If I remove that it shift tabs OK.

Is that a bug?
Peshito
Telerik team
 answered on 29 Jun 2015
2 answers
122 views

Hello,

after updating to Q2 2015, I have a strange behavior on my ribbon: the first time a tab is displayed, the text of the buttons are not correct (they are slightly larger than they should do). This behavior dissappears after selecting another tab (which shows the same problem the first time) and coming back to the previous one.

Very strange...

Evgenia
Telerik team
 answered on 29 Jun 2015
6 answers
420 views

Hi Guys,

 

I'm doing a lot of work with data in multiple threads and the RadObservableCollection is a great little gem.

 

However I have discovered an a small bug in AddRange method of the RadObservableCollection that has major implications. The AddRange method does not honour the manually set SuspendNotifications state and calls ResumeNotifications inside the method without first checking if already suspended. Any UI thread bindings monitoring for updates hit a fatal error condition.

 

As a  paid subscriber I can change the code manually but this would mean I would have to manually patch every time when new releases are made available. Would it be possible to fix this oversight?

 

Thanks,

 

Graeme

 

Graeme
Top achievements
Rank 2
 answered on 29 Jun 2015
1 answer
180 views

Hi,

I’m trying to only allow certain character in some columns (for example no letter in a columns). I’ve manage to do this easily but getting access to the TextBox’s event in the PreparingCellForEdit event.

My issue is that it does not cover the TextInput EditTrigger value, since it that will overwrite the previous value of the field. I’ve managed to get the value (the letter that was typed) from the EditingEventArgs property of the GridViewPreparingCellForEditEventArgs in the PreparingCellForEdit event by casting it to a TextCompositionEventArgs and then reading the Text property but by then, cancelling the event doesn’t not prevent the editor from being display.

Is there a better solution? Ideally I would need the TextInput EditTrigger value in the BeginningEdit event.

 

Thanks

Ivan Ivanov
Telerik team
 answered on 29 Jun 2015
4 answers
265 views
I would like to see a Lookup edit control like this one:

http://community.devexpress.com/blogs/theprogressbar/archive/2010/10/12/new-lookup-editor-control-for-wpf-and-silverlight-coming-in-v2010-vol-2.aspx

I made one with the standard controls of wpf and its slow as hell.

Do you have plans for this control in near future?
Hristo
Telerik team
 answered on 29 Jun 2015
2 answers
131 views

Good day, I can not find event  DropDownOpened in DataFormComboBoxField.

How to track opening?

form
Top achievements
Rank 1
 answered on 29 Jun 2015
1 answer
205 views

How do I remove the GridViewCell bottom border when a grouping is selected? I set the default GridViewCell to have a bottom border. When a user selects a grouping I want to remove that border. I tried to add an ExpandedStateGroup to the VisualStateManager of GridViewCellTemplate and remove the border but it didn't work: 

 

<ControlTemplate x:Key="GridViewCellTemplate" TargetType="grid:GridViewCell">
    <Grid>
        <VisualStateManager.VisualStateGroups>
            <VisualStateGroup x:Name="SelectionStates">
                <VisualState x:Name="Unselected"/>
                <VisualState x:Name="Selected"/>
            </VisualStateGroup>
            <VisualStateGroup x:Name="CommonStates">
                <VisualState x:Name="Normal"/>
                <VisualState x:Name="MouseOver">
                    <Storyboard>
                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="Background_Over" Storyboard.TargetProperty="Visibility">
                            <DiscreteObjectKeyFrame KeyTime="0">
                                <DiscreteObjectKeyFrame.Value>
                                    <Visibility>Visible</Visibility>
                                </DiscreteObjectKeyFrame.Value>
                            </DiscreteObjectKeyFrame>
                        </ObjectAnimationUsingKeyFrames>
                    </Storyboard>
                </VisualState>
            </VisualStateGroup>
            <VisualStateGroup x:Name="EditingStates">
                <VisualState x:Name="Edited">
                    <Storyboard>
                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="PART_ContentPresenter" Storyboard.TargetProperty="Margin">
                            <DiscreteObjectKeyFrame KeyTime="0">
                                <DiscreteObjectKeyFrame.Value>
                                    <Thickness>0</Thickness>
                                </DiscreteObjectKeyFrame.Value>
                            </DiscreteObjectKeyFrame>
                        </ObjectAnimationUsingKeyFrames>
                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="PART_ContentPresenter" Storyboard.TargetProperty="VerticalAlignment">
                            <DiscreteObjectKeyFrame KeyTime="0">
                                <DiscreteObjectKeyFrame.Value>
                                    <VerticalAlignment>Stretch</VerticalAlignment>
                                </DiscreteObjectKeyFrame.Value>
                            </DiscreteObjectKeyFrame>
                        </ObjectAnimationUsingKeyFrames>
                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="PART_CellBorder" Storyboard.TargetProperty="Background">
                            <DiscreteObjectKeyFrame KeyTime="0:0:0" Value="{telerik:Windows8Resource ResourceKey=MainBrush}"/>
                        </ObjectAnimationUsingKeyFrames>
                    </Storyboard>
                </VisualState>
                <VisualState x:Name="Display"/>
            </VisualStateGroup>
            <VisualStateGroup x:Name="DisabledStates">
                <VisualState x:Name="Enabled"/>
                <VisualState x:Name="Disabled">
                    <Storyboard>
                        <DoubleAnimationUsingKeyFrames Storyboard.TargetName="PART_ContentPresenter" Storyboard.TargetProperty="Opacity">
                            <DiscreteDoubleKeyFrame KeyTime="0:0:0" Value="0.3"/>
                        </DoubleAnimationUsingKeyFrames>
                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="Background_Disabled" Storyboard.TargetProperty="Visibility">
                            <DiscreteObjectKeyFrame KeyTime="0">
                                <DiscreteObjectKeyFrame.Value>
                                    <Visibility>Visible</Visibility>
                                </DiscreteObjectKeyFrame.Value>
                            </DiscreteObjectKeyFrame>
                        </ObjectAnimationUsingKeyFrames>
                    </Storyboard>
                </VisualState>
            </VisualStateGroup>
            <VisualStateGroup x:Name="ValueStates">
                <VisualState x:Name="CellValid"/>
                <VisualState x:Name="CellInvalid">
                    <Storyboard>
                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="Background_Invalid" Storyboard.TargetProperty="Visibility">
                            <DiscreteObjectKeyFrame KeyTime="0">
                                <DiscreteObjectKeyFrame.Value>
                                    <Visibility>Visible</Visibility>
                                </DiscreteObjectKeyFrame.Value>
                            </DiscreteObjectKeyFrame>
                        </ObjectAnimationUsingKeyFrames>
                    </Storyboard>
                </VisualState>
                <VisualState x:Name="CellInvalidUnfocused">
                    <Storyboard>
                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="Background_Invalid_Unfocused" Storyboard.TargetProperty="Visibility">
                            <DiscreteObjectKeyFrame KeyTime="0">
                                <DiscreteObjectKeyFrame.Value>
                                    <Visibility>Visible</Visibility>
                                </DiscreteObjectKeyFrame.Value>
                            </DiscreteObjectKeyFrame>
                        </ObjectAnimationUsingKeyFrames>
                    </Storyboard>
                </VisualState>
            </VisualStateGroup>
            <VisualStateGroup x:Name="ExpandStateGroup">
                <VisualState x:Name="Expanded">
                    <Storyboard>
                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="PART_CellBorder" Storyboard.TargetProperty="BorderThickness">
                            <DiscreteObjectKeyFrame KeyTime="00:00:00">
                                <DiscreteObjectKeyFrame.Value>
                                    <Thickness>0</Thickness>
                                </DiscreteObjectKeyFrame.Value>
                            </DiscreteObjectKeyFrame>
                        </ObjectAnimationUsingKeyFrames>
                    </Storyboard>
                </VisualState>
                <VisualState x:Name="Collapsed"/>
            </VisualStateGroup>
        </VisualStateManager.VisualStateGroups>
        <Border x:Name="PART_CellBorder"
                Background="{Binding Background, RelativeSource={RelativeSource TemplatedParent}}"
                BorderBrush="{TemplateBinding VerticalGridLinesBrush}"
                BorderThickness="{Binding VerticalGridLinesWidth, RelativeSource={RelativeSource TemplatedParent}, Converter={StaticResource GridLineWidthToThicknessConverter}, ConverterParameter=Right}"/>
        <Border x:Name="Background_Over"
                Background="{telerik:Windows8Resource ResourceKey=StrongBrush}"
                Opacity="0.15"
                BorderBrush="{TemplateBinding VerticalGridLinesBrush}"
                BorderThickness="{Binding VerticalGridLinesWidth, RelativeSource={RelativeSource TemplatedParent}, Converter={StaticResource GridLineWidthToThicknessConverter}, ConverterParameter=Right}"
                Grid.Column="2"
                Grid.ColumnSpan="2"
                Visibility="Collapsed"/>
        <Border x:Name="Background_Selected"
                Background="{telerik:Windows8Resource ResourceKey=BasicBrush}"
                BorderBrush="{TemplateBinding VerticalGridLinesBrush}"
                BorderThickness="{Binding VerticalGridLinesWidth, RelativeSource={RelativeSource TemplatedParent}, Converter={StaticResource GridLineWidthToThicknessConverter}, ConverterParameter=Right}"
                Grid.Column="2"
                Grid.ColumnSpan="2"
                Visibility="Collapsed"/>
        <Border x:Name="Background_Invalid_Unfocused"
                Visibility="Collapsed"
                BorderThickness="1"
                BorderBrush="{telerik:Windows8Resource ResourceKey=ValidationBrush}"
                Grid.Column="2"
                Grid.ColumnSpan="2"
                Opacity="1"/>
        <Border x:Name="Background_Invalid"
                Background="{telerik:Windows8Resource ResourceKey=MainBrush}"
                BorderThickness="1"
                BorderBrush="{telerik:Windows8Resource ResourceKey=ValidationBrush}"
                Grid.Column="2"
                Grid.ColumnSpan="2"
                Visibility="Collapsed">
            <ToolTipService.ToolTip>
                <ToolTip x:Name="validationTooltip" Placement="Right" Content="{TemplateBinding Errors}" Template="{StaticResource GridViewCell_ValidationToolTipTemplate}"/>
            </ToolTipService.ToolTip>
            <Grid Height="22" HorizontalAlignment="Right" VerticalAlignment="Top" Width="22" Background="Transparent">
                <Path
                        Data="M0,0 L4,0 L4,4 z"
                        Fill="{telerik:Windows8Resource ResourceKey=ValidationBrush}"
                        Stretch="Fill"
                        Margin="0,1,1,0"
                        Height="4"
                        VerticalAlignment="Top"
                        HorizontalAlignment="Right"
                        Width="4"/>
            </Grid>
        </Border>
        <Border x:Name="Background_Disabled" Background="{telerik:Windows8Resource ResourceKey=MainBrush}" Opacity="0.3" Grid.Column="2" Grid.ColumnSpan="2" Visibility="Collapsed"/>
        <ContentPresenter x:Name="PART_ContentPresenter"
                Margin="{TemplateBinding Padding}"
                Content="{TemplateBinding Content}"
                ContentTemplate="{TemplateBinding ContentTemplate}"
                VerticalAlignment="{TemplateBinding VerticalContentAlignment}"
                HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}"/>
    </Grid>
</ControlTemplate>
<Style x:Key="GridViewCellStyle" TargetType="grid:GridViewCell">
    <Setter Property="Template" Value="{StaticResource GridViewCellTemplate}"/>
    <Setter Property="BorderBrush" Value="{telerik:Windows8Resource ResourceKey=BasicBrush}"/>
    <Setter Property="Padding" Value="5,0,3,0"/>
    <Setter Property="BorderThickness" Value="0,0,1,0"/>
    <Setter Property="VerticalContentAlignment" Value="Center"/>
    <Setter Property="HorizontalContentAlignment" Value="Stretch"/>
    <Setter Property="Background" Value="Transparent"/>
    <Setter Property="SnapsToDevicePixels" Value="True"/>
    <Setter Property="FocusVisualStyle" Value="{StaticResource FocusVisualStyle}"/>
</Style>

Dimitrina
Telerik team
 answered on 26 Jun 2015
4 answers
868 views

Any ideas how I can create a small floating window (modal) over and existing WPF window?

I want to show a digital clock on the window/form at all times.

 

thanks in advance

Jonathan
Top achievements
Rank 1
Iron
Veteran
 answered on 26 Jun 2015
2 answers
166 views
How can I change font size for Telerik RadScheduleView's date at the upper tab/menu (don't know how to name it)? I want to make the size of type bigger. There is a lot information about styling appointments on the Telerik website but nothing about styling that menu. The text I need to change font size for is highlited on the image.
Maxim
Top achievements
Rank 1
 answered on 26 Jun 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
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
+? more
Top users last month
Miljana
Top achievements
Rank 2
Iron
Iron
Joel
Top achievements
Rank 3
Bronze
Bronze
Bronze
Cynthia
Top achievements
Rank 1
John
Top achievements
Rank 1
Iron
Mozart
Top achievements
Rank 1
Iron
Veteran
Want to show your ninja superpower to fellow developers?
Top users last month
Miljana
Top achievements
Rank 2
Iron
Iron
Joel
Top achievements
Rank 3
Bronze
Bronze
Bronze
Cynthia
Top achievements
Rank 1
John
Top achievements
Rank 1
Iron
Mozart
Top achievements
Rank 1
Iron
Veteran
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?