Telerik blogs

Latest

  • Web ASP.NET AJAX

    Integrating RadEditor for ASP.NET AJAX with the WIRIS family of products

    We have received several requests to integrate a formula editor for RadEditor or allow editing of MathML. The wonderful guys at WIRIS(http://www.wiris.com/) have the right tools for this job so we decided to post an example of the WIRIS formula editor and CAS working as RadEditor dialogs.   A couple of words about the formula editor - it uses a Java applet so be sure to have the Java plugin installed in your browser. We used the basic ASPX demo that WIRIS offers as a base for our integration example. The demo can be seen here - http://www.wiris.eu/demo-aspx/pluginwiris/generic/. There are two editors...
    April 30, 2009
  • Web

    Using IValueConverter to format values in RadControls for Silverlight

    It’s often necessary to modify or format some of the raw data received by your data tier application or other data sources. In Silverlight, you can create your own value converter and introduce your own formatting rules. In this blog post I will create a simple value converter that formats double values, and then use it with a RadComboBox. First, let’s create a class that will represent our data source. The equivalent of this class in more realistic scenario would be a proxy class generated by your data tier application in case you use RIA services.     public class Data : List<Item>       {           public Data()           {               this.Add(new Item() { Name = "Ferrari", Price = 120000 });               this.Add(new Item() { Name = "Mercedes", Price = 100000 });...
    April 29, 2009
  • Web

    Designing N-Tier Applications with OpenAccess ORM

    A very important question recently crossed my inbox, and it essentially asked: “Can you design and build Enterprise-grade n-tier applications with OpenAccess? Or does it force you violate principles of good multi-tier application design to make the ORM features work?” It was a great question and I was surprised to find that there is not more info in the online docs to address this. So, to help everyone benefit from this question’s answer, here are some details about building n-tier applications with OpenAccess. WHAT DOES GOOD N-TIER ARCHITECTURE LOOK LIKE WITH OPENACCESS? Let me preface this discussion by saying there is no “absolute” right...
    April 28, 2009
  • Web

    Attaching a ContextMenu on a TreeView with RadControls for Silverlight

    Telerik RadControls for Silverlight provide a very powerful ContextMenu control, that supports right click, modifier keys and that can be easily attached to any visual element. In this article I will show how to attach RadContextMenu to a data-bound RadTreeView and perform actions on the clicked treeview items, depending on the selection in the context menu. For simplicity, here I will use a treeview, bound to a static collection, but it can be easily extended to load its items from a web service: <UserControl x:Class="ContextMenuInTreeView.Page" xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" xmlns:local="clr-namespace:ContextMenuInTreeView" xmlns:telerik="clr-namespace:Telerik.Windows.Controls;assembly=Telerik.Windows.Controls" xmlns:telerikNavigation="clr-namespace:Telerik.Windows.Controls;assembly=Telerik.Windows.Controls.Navigation"> <UserControl.Resources> <local:DataViewModel x:Key="ViewModel" /> <telerik:HierarchicalDataTemplate x:Key="TreeViewItemTemplate" ItemsSource="{Binding Children}"> <TextBlock Text="{Binding Text}"> <telerikNavigation:RadContextMenu.ContextMenu> <telerikNavigation:RadContextMenu> <telerikNavigation:RadMenuItem Header="New Child" /> <telerikNavigation:RadMenuItem Header="New Sibling" /> <telerikNavigation:RadMenuItem Header="Delete" /> </telerikNavigation:RadContextMenu> </telerikNavigation:RadContextMenu.ContextMenu> </TextBlock> </telerik:HierarchicalDataTemplate> </UserControl.Resources> <StackPanel Background="White" DataContext="{StaticResource...
    April 27, 2009
  • Web

    Lightweight DataTable for your Silverlight applications

      UPDATE: Please visit this post for more info about dynamic objects binding!   Since there is no DataTable in Silverlight I’ve created small class that can be used to generate columns and rows in runtime in similar to the real DataTable way: DataTable table = new DataTable();table.Columns.Add(new DataColumn() { ColumnName = "ID", DataType = typeof(int) });table.Columns.Add(new DataColumn() { ColumnName = "Name", DataType = typeof(string) });table.Columns.Add(new DataColumn() { ColumnName = "UnitPrice", DataType = typeof(decimal) });table.Columns.Add(new DataColumn() { ColumnName = "Date", DataType = typeof(DateTime) });table.Columns.Add(new DataColumn() { ColumnName = "Discontinued", DataType = typeof(bool) });for(var i = 0; i < 1000; i++){ DataRow row = new DataRow(); row["ID"]...