Telerik Forums
UI for WPF Forum
9 answers
183 views

I'm handling the ColumnWidthChanged event and saving the width of each column in a config file for reuse the next time my application is run. If I drag the column to a different size the NewWidth property is the actual width I've chosen. If I double-click the column edge to auto-size it, the NewWidth property is set to "Auto" and the value is "1".

Why can't I see what the actual new width is? My gut says this is counter-intuitive, but Telerik generally has a good reason for this sort of thing.

Any input as to how I can get the actual width so I can save it?

Yoan
Telerik team
 answered on 04 Jul 2017
5 answers
323 views

Hello,

 

I have an issue with snap to grid and resizing. Consider SnapX and Snap Y  is set to 20 and Grid Cell Size is set to 20 as well. Then add a rectangle Shape and set its position to 23 and 23 while snap to grid is enabled try to enlarge the shape from bottom right corner. The shape width and height will increment by 20 so the width and height become 43 and 43 instead of 40 and 40 which are the grid lines position.

Am I missing something here ?

Thanks,

Bruno
Top achievements
Rank 1
 answered on 03 Jul 2017
2 answers
161 views
Bug: RadTabControl does not scroll only a single item but the entire collection when ScrollMode="Item" and TabStripPlacement="Left". Is there a known workaround for this?
Dinko | Tech Support Engineer
Telerik team
 answered on 03 Jul 2017
2 answers
190 views
I have a RadHeatMap that takes about 10 seconds to render  700,000 data points.  I have a RadBusyIndicator to show that the data is being loaded.  Is there an event or some way to tell when the data is finished binding and the heatmap has finished rendering so i can change the busy property of the RadBusyIndicator?  
Rihana
Top achievements
Rank 1
 answered on 03 Jul 2017
1 answer
93 views

Hi,

 

I would like to personnalize the ContainerShape but if i change Template property, all events (resize, connector) disappear.

Do you have a example of a full personnalized ContainerShape ?

Thanks.

This is my code

<Setter Property="Template">
    <Setter.Value>
        <ControlTemplate>
            <Grid Background="DimGray">
                <Grid.RowDefinitions>
                    <RowDefinition Height="35"></RowDefinition>
                    <RowDefinition Height="*"></RowDefinition>
                </Grid.RowDefinitions>
                <StackPanel Orientation="Horizontal" HorizontalAlignment="Center" Grid.Row="0">
                    <TextBlock x:Name="EntityContent" Text="test" Width="250" Height="35" Foreground="White" />
                </StackPanel>
                <Grid Grid.Row="2">
                    <Grid.ColumnDefinitions>
                        <ColumnDefinition Width="40*" />
                        <ColumnDefinition Width="20*" />
                        <ColumnDefinition Width="40*" />
                    </Grid.ColumnDefinitions>
                    <StackPanel Orientation="Vertical" x:Name="EntityDataIn" Grid.Column="0"></StackPanel>
                    <StackPanel Orientation="Vertical" x:Name="EntityDataOut" Grid.Column="2"></StackPanel>
                </Grid>
            </Grid>
        </ControlTemplate>
    </Setter.Value>
</Setter>
Dinko | Tech Support Engineer
Telerik team
 answered on 03 Jul 2017
1 answer
347 views

Hi,

 

I try to bind Stroke, strokeThickness and StrokeDashArray properties. I try manually and with ItemInformationAdorner.AdditionalContent but that's doesn't work.

Can you help me pls ?

This is my code

<telerik:RadDiagram Position="0,0" x:Name="tlrDiagram" ContainerShapeStyle="{StaticResource entityStyle}">
                <telerik:EventToCommandBehavior.EventBindings>
                    <telerik:EventBinding Command="{Binding ItemsChangingCommand}" EventName="ItemsChanging" RaiseOnHandledEvents="True" PassEventArgsToCommand="True" />
                </telerik:EventToCommandBehavior.EventBindings>
                <telerik:RadDiagramContainerShape x:Name="src" Width="50" Height="50" Position="10,10" BorderThickness="0"   StrokeThickness="3" StrokeDashArray="1" Stroke="Red" />
                <telerik:RadDiagramContainerShape x:Name="dest"  Width="50" Height="50" Position="150,150" Stroke="blue" StrokeThickness="3" StrokeDashArray="1" />
                <telerik:RadDiagramConnection Source="{Binding ElementName=src}" Target="{Binding ElementName=dest}" Stroke="GreenYellow" StrokeThickness="3" StrokeDashArray="1" />
                <primitives:ItemInformationAdorner.AdditionalContent>
                    <telerik:SettingsPane Diagram="{Binding ElementName=tlrDiagram}" />
                </primitives:ItemInformationAdorner.AdditionalContent>
            </telerik:RadDiagram>

 

 

 

<Style x:Key="entityStyle" TargetType="telerik:RadDiagramContainerShape">
       <Setter Property="IsEditable" Value="True" />
       <Setter Property="IsResizingEnabled" Value="False" />
       <Setter Property="HorizontalContentAlignment" Value="Center" />
       <Setter Property="VerticalContentAlignment" Value="Center" />
       <Setter Property="IsConnectorsManipulationEnabled" Value="False" />
       <Setter Property="IsCollapsible" Value="false" />
       <Setter Property="Padding" Value="0" />
       <Setter Property="IsCollapsed" Value="false" />
       <Setter Property="Background" Value="DimGray" />
       <Setter Property="Foreground" Value="Black" />
       <Setter Property="BorderBrush" Value="White" />
       <Setter Property="BorderThickness" Value="1" />
       <Setter Property="FontFamily" Value="Segoe UI" />
       <Setter Property="Width" Value="250" />
       <Setter Property="Margin" Value="0" />
       <Setter Property="Effect">
           <Setter.Value>
               <DropShadowEffect BlurRadius="15"
                                 Direction="-90"
                                 ShadowDepth="2"
                                 RenderingBias="Quality"/>
           </Setter.Value>
       </Setter>
   </Style>

 

 

 

 

Dinko | Tech Support Engineer
Telerik team
 answered on 03 Jul 2017
0 answers
93 views

I have 2 Gridviews. Gridview B is nested inside GridView A. GridView B's ItemsSource comes from A.SelectedAttachments.

When I select a row in gridview B is there a way to programatically select GridViewA? I want to try to remove a row inside gridview B but how would I do that if I don't know the parent object it belongs to. 

 

My main goal is to be able to remove items from A.SelectedAttachments through a context menu of GridView B.

<DataTemplate x:Key="RowDetailTemplate">
    <telerik:RadGridView ItemsSource="{Binding SelectedAttachments}" Style="{StaticResource StdGrid}" >
        <telerik:RadGridView.Columns>
            <telerik:GridViewDataColumn Header="File" DataMemberBinding="{Binding FileName}"  />
            <telerik:GridViewDataColumn Header="Source Document" DataMemberBinding="{Binding Description}" EditTriggers="CellClick" IsReadOnly="False">
                <telerik:GridViewDataColumn.CellEditTemplate>
                    <DataTemplate>
                        <TextBox Text="{Binding Description}" Foreground="Gray" FontStyle="Italic" ></TextBox>
                    </DataTemplate>
                </telerik:GridViewDataColumn.CellEditTemplate>
                <telerik:GridViewDataColumn.CellTemplate>
                    <DataTemplate>
                        <TextBox Text="{Binding Description}" Foreground="Gray" FontStyle="Italic"></TextBox>
                    </DataTemplate>
                </telerik:GridViewDataColumn.CellTemplate>
            </telerik:GridViewDataColumn>
        </telerik:RadGridView.Columns>
    </telerik:RadGridView>
</DataTemplate>
band
Top achievements
Rank 1
 asked on 30 Jun 2017
5 answers
208 views

Hi,

We are using VQCV (Telerik 2016.2.503.40) to virtualize data to RadGridView from the server side to client, sometimes the grid doesn't refresh correctly the new added items (we had a workaround with an explicit call to the .Refresh() function in the end of the data loading routine), unfortunately this causes a freeze of the main Thread on Windows10.

This problem exists also in the telerik Demo panel (see the attached file).

01.Task.Factory.StartNew(() =>
02.{
03.    // Getting data from the server Side
04.    return result;
05. 
06.}).ContinueWith(finLazyLoading =>
07.{
08.   // DataVirtualisationRoutine...
09. 
10.    MyVQCV.VirtualItemCount = collection.ItemsCount;
11. 
12.    MyVQCV.Load(currentOffset, collection.Items);
13. 
14.    // If we call the refresh here it occurs the bug on Win10 (total freeze of the app).
15. 
16.}, TaskScheduler.FromCurrentSynchronizationContext()).ContinueWith(fixwin10 =>
17.{
18.    // This call causes an infinite loop... :(
19.
20.    MyVQCV.Refresh();
21. 
22.}, TaskScheduler.FromCurrentSynchronizationContext());

Can we have a fixe for this please or a working solution, we don't know how to do.

Thank you!

DenisCL
Top achievements
Rank 1
 answered on 30 Jun 2017
6 answers
676 views
I'm using the RadNumericUpDown in an application that requires several numeric inputs, about 20 on a single screen.
I like the UpDown ability (being able to click an arrow up and down), however I also need the user to be able to just enter in some numbers.  Well I've run into an issue, and I'm wondring if it's expected behavior or a bug.

if I highlight the text in the RadNumericUpDown box, and begin to type, lets say I type "200".  The first number gets intered ("2") but after that the cursor moves the the very far left, and the next number ("0") is entered to the left.  So what actually appears in the box is "002".  It appears to me as though you have to think in reverse to enter a number.  this seems counter intuitive.  Is this normal behavior or am i just missing a setting.  Here's the code I'm using

        <Style x:Key="Numbers" TargetType="{x:Type Tel:RadNumericUpDown}"
            <Setter Property="Width" Value="100"/> 
            <Setter Property="Margin" Value="10"/> 
            <Setter Property="Minimum" Value="0"/> 
            <Setter Property="FontSize" Value="12"/> 
        </Style> 
 
                    <Tel:RadNumericUpDown Grid.Row="0" Grid.Column="1" Style="{StaticResource Numbers}" 
                                      ValueFormat="Numeric" IsEditable="True"  
                                      Minimum="0" Maximum="100000"  
                                      Value="{Binding Path=MaxPumpOutRate.DisplayValue}"></Tel:RadNumericUpDown> 
 
 

in this example "MaxPumpOutRate" is my model object, and it has a property of type double named "DisplayValue"

Thanks for any help
Dinko | Tech Support Engineer
Telerik team
 answered on 30 Jun 2017
3 answers
155 views

Hi all

 

I've a Strange error... 

The pdfviewer don't show anything but if i print the document it exists !

 

The code work normaly before i don't understand.....

this is the XAML code

<Window x:Class="TestPdfViewer.MainWindow"
        xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
        xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
        xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
        xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
        xmlns:UC="clr-namespace:Angdm.Framework.UI.UserControls;assembly=Angdm.Framework.UI"
        xmlns:telerik="http://schemas.telerik.com/2008/xaml/presentation"
        xmlns:local="clr-namespace:TestPdfViewer"
        mc:Ignorable="d"
        Title="MainWindow" Height="350" Width="525" Loaded="Window_Loaded">
    <Grid >
        <telerik:RadPdfViewer x:Name="pdfviewer"/>
        <!--<UC:UCPdfViewer x:Name="pdfviewer" BorderBrush="Red"/>-->
    </Grid>
</Window>

 

and the window loaded

 

   private void Window_Loaded(object sender, RoutedEventArgs e)
        {
            using (FileStream fs = new FileStream("c:\\toto.pdf", FileMode.Open, FileAccess.Read))
            {
                byte[] byteread = new byte[fs.Length];
                int numBytesToRead = (int)fs.Length;
                int numBytesRead = 0;
                while (numBytesToRead > 0)
                {
                    int n = fs.Read(byteread, numBytesRead, numBytesToRead);

                    if (n == 0)
                        break;
                    numBytesRead += n;
                    numBytesToRead -= n;
                }
                numBytesToRead = byteread.Length;
               
                MemoryStream m = new MemoryStream(byteread);
                FormatProviderSettings settings = new FormatProviderSettings(ReadingMode.AllAtOnce);
                PdfFormatProvider provider = new PdfFormatProvider(m, settings);
                RadFixedDocument mdoc_data = provider.Import();
                this.pdfviewer.ClearDocument();
                this.pdfviewer.Document = mdoc_data;


            }
        }

Tanya
Telerik team
 answered on 30 Jun 2017
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?