Telerik Forums
UI for WPF Forum
3 answers
72 views

Hello, 

Using the latest WPF controls,  I need to add inside a RadWindow, a RadTimePicker or RadDatePicker. 
When I run the application the controls are displayed correctly, but when I try to open the datepicker, I get the attached error.

I`ve added the NoXML dlls and in the App.XAML I`ve added the Windows8Touch theme for each control.
Note that, independently, all controls are working perfectly fine, but in this case I don`t understand what is the problem. Am I missing something ?
Details of the sistem : Windows 8.1 x64

Nasko
Telerik team
 answered on 26 May 2015
10 answers
403 views
Hello!
I use the following line in my code:
this.telerikChart.DefaultView.ChartArea.AxisY.DefaultLabelFormat = "#VAL{N0} " + unitName + " ";



I try to format the Y axis labels in a way that it shows the actual value concatenated with a specific unit name, but the way provided by you in the tutorial give me only rounded values concatenated with the unit name - like in the image attached labelformat.png - and I get on Y axis few times 0 values, few 1 values and not the real values that I need (shown correctly but without unit in labelformatnorounding.png)

What is the correct format string if I don.t want this rounding?

Thank you!
Roxana

Martin Ivanov
Telerik team
 answered on 26 May 2015
1 answer
161 views

Hello.
Is it possible to use RadRibbonBackstageItem  with prism?
I try to use navigation but view doesn't appears.

 <telerik:RadRibbonBackstageItem Header="Info" IsDefault="True" Command="{Binding NewCommand}" CommandParameter="Info" >
               <ContentControl regions:RegionManager.RegionName="RadRibbonViewRegion" />
</telerik:RadRibbonBackstageItem>

...

 var regionManager = ServiceLocator.Current.GetInstance<IRegionManager>();
regionManager.RequestNavigate("RadRibbonViewRegion", new Uri("New", UriKind.Relative));

 

 

 

Kiril Vandov
Telerik team
 answered on 26 May 2015
3 answers
177 views

Hi,

I tried to load a complex 3D project exported as KMZ from Sketchup. Nothing appears...
You have planned a complete support for Kml specifications?
If not, exists another way to show a sketchup project into a RadMap (or other control)?

thanks
marc.

Petar Mladenov
Telerik team
 answered on 26 May 2015
1 answer
152 views

Hi,

 

I'm using VS2013 with the latest version of Telerik and I have a problem in design mode. When I have multiple RadTabItem, if I click on a RadTabItem, the designer don't show the content of the RadTabItem I clicked on. It work only if it's the first one.

 

Thank's

Alain

Milena
Telerik team
 answered on 26 May 2015
3 answers
397 views
We have a RadDateTimePicker in a window.
When the window opens, we want to set focus on the RadDateTimePicker.
So we use 
         public OurWindow()
        {
            InitializeComponent();
            OurDateTimePicker.Focus();
        }
When openeing the window, we see the orange border (Office-theme) that indicates that the RadDateTimePicker has focus. When pushing the Arrow-Down-key the calendar opens. Great!
But, our customers also want the possibility to can write immediately in the box. How could we do this?
When we set focus from codebehind, the text in the box is not selected and there is no beam in the box.

We alse tried to set focus after the window was loaded and activated. 
Nasko
Telerik team
 answered on 26 May 2015
3 answers
264 views

In my application I have a datagrid and one of the column is a column with a richtextbox. There are about 30 rows in the datagrid and loading of each richtextbox take some time, so loading of 30 richtextboxes take a lot of time. 

Is there any way to improve loading speed of datagrid with richtextboxes? Maybe they can use the same background logic instead of separated for each item.

If it could help, at the same time only one richtextbox can be editable. So, by default row is read only, but user can edit only one at the same time.

 Thanks

 

Best Regards,

Grigory

Grigory
Top achievements
Rank 2
 answered on 25 May 2015
3 answers
264 views

I am using EF 6 to connect to a database in a WPF app using MVVM pattern.  I have a derived context like so:

 

public class TIMSContext : DbContext
  {
      public TIMSContext()
          : base("name=TIMSContext") { }
 
 
      protected override void OnModelCreating(DbModelBuilder modelBuilder)
      {
          //map models...
      }
 
      public IQueryable<T> Query<T>()
      {
          return this.Set(typeof(T)).AsQueryable() as IQueryable<T>;
      }
 
  }

 

I want to use the EntityFrameworkDataSource to provide items to a RadGridView so that I don't have to write the paging/filtering code myself.  I have looked at the example, but I cannot get it to work.

 

My XAML:

<telerik:RadGridView x:Name="RadGridView1"
                               Grid.Row="0"
                               AlternateRowBackground="CornflowerBlue"
                               AlternationCount="2"
                               AutoGenerateColumns="True"
                               CanUserDeleteRows="False"
                               CanUserFreezeColumns="False"
                               CanUserInsertRows="False"
                               GroupRenderMode="Flat"
                               IsReadOnly="True"
                               ItemsSource="{Binding ShipmentData}"
                               RowIndicatorVisibility="Collapsed" />
 
          <telerik:RadDataPager Grid.Row="1"
                                DisplayMode="FirstLastPreviousNextNumeric"
                                PageSize="25"
                                Source="{Binding ShipmentData}"/>

 

Here is my Viewmodel:

public class ShipmentsViewModel :ViewModelBase
    {
        private readonly QueryableEntityCollectionView<TIMS.Data.Entities.ASN> shipments;
        private readonly TIMS.Data.TIMSContext ctx;
 
        public ShipmentsViewModel()
        {
            try
            {
                ctx = new Data.TIMSContext();
                shipments = new QueryableEntityCollectionView<Data.Entities.ASN>(ctx, "ASN");
                //Argument 1: cannot convert from 'TIMS.Data.TIMSContext' to 'System.Data.Objects.ObjectContext'
 
 
                //Also tried this which I saw on some forums...
                //shipments = new QueryableEntityCollectionView<Data.Entities.ASN>( ((IObjectContextAdapter)ctx).ObjectContext, "ASN");
                //Argument 1: cannot convert from 'System.Data.Entity.Core.Objects.ObjectContext' to 'System.Data.Objects.ObjectContext'
            
            }
            catch (Exception)
            {
            }
        }
 
        #region Properties
 
        public Object ShipmentData
        {
            get
            {
                return shipments;
            }
        }
         
        #endregion
}

Dimitrina
Telerik team
 answered on 25 May 2015
1 answer
229 views

Hallo,

 

I'd like to ask about my problem. I have app where i'm working with tabControl and RadDiagram. First RadDiagram is created in  xaml code and it's loaded manualy with some logic from the xml file. DragDrop logic is based on your DragDrop tutorial and it's working fine. But when i try create diagram manualy behind the code with my own method which is defining the most important things in diagram i don't know how to make it works with my DragDropBehavior Class.

How could i define dragDrop:DragDropBehaviorRadDiagram.IsEnabled="True" behind code when i'm create new diagram?

 

thank you for your time and advices

 

Grettings 

Jakub Rautner

private RadDiagram CreateNewDiagram()
       {
           RadDiagram dgrm = new RadDiagram();
 
          // Events handlers
           dgrm.ShapeDoubleClicked += new EventHandler<ShapeRoutedEventArgs>(diagram_ShapeDoubleClicked);
           dgrm.MouseDoubleClick += new MouseButtonEventHandler(diagram_MouseDoubleClick);
           dgrm.SelectionChanged += new SelectionChangedEventHandler(diagram_SelectionChanged);
           dgrm.ZoomChanged += new EventHandler<RadRoutedPropertyChangedEventArgs<double>>(diagram_ZoomChanged);
 
 
           DragDropManager.AddDropHandler(dgrm, OnDrop);
 
           dgrm.Style = this.Resources["diagramStyle"] as Style;
           dgrm.ShapeStyleSelector = xGrid.Resources["CustomShapeStyleSelector"] as NodeStyleSelector;
           dgrm.ConnectionStyleSelector = xGrid.Resources["CustomConnectionStyleSelector"] as LinkStyleSelector;
 
           dgrm.LayoutAsync(LayoutType.Tree, TreeSettings);
 
           dgrm.IsDraggingEnabled = true;
           dgrm.AllowDrop = true;
 
           return dgrm;
       }

 

Here' s definition RadDiagram in xaml file:  dragDrop is namespace where i have created DragDropBehavior logic for TreeView and RadDiagram 

<telerik:RadDiagram x:Name="diagram" Grid.Row="0"
  ShapeStyleSelector="{StaticResource CustomShapeStyleSelector}"
  ConnectionStyleSelector="{StaticResource CustomConnectionStyleSelector}"
  Style="{StaticResource diagramStyle}"
  ZoomChanged="diagram_ZoomChanged"                                                    IsZoomEnabled="True"                                                      MouseDoubleClick="diagram_MouseDoubleClick"                                                    AllowDrop="True"                                                    dragDrop:DragDropBehaviorRadDiagram.IsEnabled="True"                                                    ShapeDoubleClicked="diagram_ShapeDoubleClicked"                                                    SelectionChanged="diagram_SelectionChanged">                                    <primitives:ItemInformationAdorner.AdditionalContent>                                        <telerik:SettingsPane x:Name="xSettingsPane" Diagram="{Binding ElementName=diagram}">                                        </telerik:SettingsPane>                                    </primitives:ItemInformationAdorner.AdditionalContent>                                </telerik:RadDiagram>

 

Petar Mladenov
Telerik team
 answered on 25 May 2015
1 answer
162 views

Hi,

I am trying to have a single chart with a Stacked 100 Bar series with a Line Series over it, however the line series doesn't want to show.

 

Example code:

<telerik:RadCartesianChart.Series>
                    <telerik:BarSeries x:Name="barSeries1" CategoryBinding="MyDateTime"
                                   ValueBinding="RedValue"
  ItemsSource="{Binding MyDataSource}"
  CombineMode="Stack100">
                        <telerik:BarSeries.PointTemplate>
                            <DataTemplate>
                                <Rectangle Fill="Red"/>
                            </DataTemplate>
                        </telerik:BarSeries.PointTemplate>
                    </telerik:BarSeries>
                        <telerik:BarSeries x:Name="barSeries2" CategoryBinding="MyDateTime"
                                   ValueBinding="GreenValue"
  ItemsSource="{Binding MyDataSource}"
                                           CombineMode="Stack100"
  >
                        <telerik:BarSeries.PointTemplate>
                            <DataTemplate>
                                <Rectangle Fill="Green"/>
                            </DataTemplate>
                        </telerik:BarSeries.PointTemplate>
                    </telerik:BarSeries> 
                    <telerik:LineSeries x:Name="lineSeries1" CategoryBinding="MyDateTime" ValueBinding="MyValue" Stroke="Black" 
  ItemsSource="{Binding MyDataSource}"
   />
</telerik:RadCartesianChart.Series>

 Any assistance would be greatly appreciated.

Anna
Telerik team
 answered on 25 May 2015
Narrow your results
Selected tags
Tags
+? more
Top users last month
Jay
Top achievements
Rank 3
Iron
Iron
Iron
Benjamin
Top achievements
Rank 3
Bronze
Iron
Veteran
Radek
Top achievements
Rank 2
Iron
Iron
Iron
Bohdan
Top achievements
Rank 2
Iron
Iron
Richard
Top achievements
Rank 4
Bronze
Bronze
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Jay
Top achievements
Rank 3
Iron
Iron
Iron
Benjamin
Top achievements
Rank 3
Bronze
Iron
Veteran
Radek
Top achievements
Rank 2
Iron
Iron
Iron
Bohdan
Top achievements
Rank 2
Iron
Iron
Richard
Top achievements
Rank 4
Bronze
Bronze
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?