Telerik blogs

Latest

  • Productivity

    Using the DragDropService in RadDock

    Overview The new docking framework introduces service-based semantic, which allows for granular and pluggable functionality per RadDock. Entire drag-and-drop functionality is handled by the registered DragDropService instance, which simply receives drag requests and instantiates the appropriate operation. The service is responsible for drop target hit-testing, displaying docking guides and docking hints as well as for processing user input while dragging is in progress. On the screen above, toolWindow3 instance is being dragged. The service has hit-tested the MainDocumentContainer as a drop anchor and the appropriate docking guide is displayed. The “Left” docking position is selected and the service “hints” the user...
    May 27, 2021 4 min read
  • Web

    How To: Easy printing with Telerik RadGridView for Silverlight

    Using export to HTML feature you can print the grid very easily just by adding following JavaScript to the export output: <script type=""text/javascript"">print();</script> You can use WebClient to save the output as file on the server: Silverlight client side: Uri uri = new Uri(HtmlPage.Document.DocumentUri, String.Format("PrintHandler.aspx?FileName={0}", fileName)); WebClient client = new WebClient(); client.UploadStringCompleted += new UploadStringCompletedEventHandler(client_UploadStringCompleted); client.UploadStringAsync(uri, String.Format("{0}{1}", RadGridView1.ToHtml(), printScript)); ASP.NET server side: protected void Page_Load(object sender, EventArgs e) { if (Request.QueryString["FileName"] != null) { File.WriteAllText(Server.MapPath(Request.QueryString["FileName"]), new StreamReader(Request.InputStream).ReadToEnd(), Encoding.UTF8); } } and request this file when upload...
    May 27, 2021 1 min read
  • Productivity

    Using Interceptors with Ado.Net Data Services and Telerik OpenAccess ORM

    ADO.NET Data Services enables an application to intercept request messages so that you can add custom logic to an operation. You can use this custom logic to validate data that goes to the client or returns to be persisted on the server. You can also use it to modify and filter further the scope of a query request, or add in that way a custom authorization policy on a per request basis. Interception is performed by specially attributed methods in the data service. These methods are called by ADO.NET Data Services at the appropriate point in message processing. Interceptors cannot accept...
    May 27, 2021 2 min read
  • Productivity

    Using the ObjectContainer in disconnected scenarios – Part 2

    How to get objects into the ObjectContainer? The ObjectContainer contains a closed world of instances, no reference is dangling and pointing out of the container. That means, the instance graph is contained completely in this 'workspace'. Of course, at some points the need arises to prune the graph, as otherwise the whole database content would need to be stored in the containers memory. This is no different to the connected IObjectScope, but in the scope, we can directly perform the loading of objects from the database (lazy loading). With the container, there is no connection to a database,...
    May 27, 2021 3 min read
  • Desktop WinForms

    Menu Merge (RadControls for WinForms)

    The long established traditions of the MDI interface makes menu merge indispensable for any WinForms Controls library. The MDI user interface is well known across the users and perhaps the most famous application that employed it for more than a decade is Microsoft Office (up to version 2003). Even though the new Ribbon Bar look snazzier to me, I am sure that the folks that are using Menus in MDI forms will appreciate this new feature.   Our MDI implementation covers two things – RadForm and RadMenu. Both are really independent and for this reason you can mix RadForms and standard forms as well...
    May 27, 2021 1 min read
  • Desktop WinForms

    New RSS feeds available for RadControls for WinForms

    As a company, it has always been our priority to be as transparent and up-front with the work we do for you as possible. This is why we have extended the available RSS feeds for all product lines, including for RadControls for WinForms. This will allow you to get the most recent news directly in your RSS reader, without the need to visit our site. In addition to the already available WinForms Support Feed, which provides you with information on new Code Library projects and new Knowledge Base articles on RadControls for WinForms, we add the following feeds on new help articles, new...
    July 23, 2009 1 min read
  • Productivity

    Using LinqPad with Telerik OpenAccess ORM

    LinqPad is a nice and popular query analyzer made to test LINQ queries: whether it is Linq To Sql, Linq to Objects or some other flavor, you will be able to play in a nice way with it. Sadly it does not support Telerik OpenAccess ORM out of the box. However we never said it is impossible – you just have to put some more pressure to it. So, the first step is of course to deploy Telerik OpenAccess ORM and LinqPad on your machine. Then do the following: a) Open LinqPad and press F4 to bring up the Advanced Query...
    May 27, 2021 2 min read
  • Productivity

    LINQ Tip of the Week: Optimizing query execution by using parameterized queries

    This is the first post of the series that have the goal to help Telerik OpenAccess ORM users enhance their experience in Linq against OpenAccess persistent objects. The two areas where performance enhancement can be taken advantage of are reusing a Linq query from the query cache and altering the query in a way where bigger portions of it are executed on the server. Today we will share with you a tip about the first one. When a Linq query is requested for execution, the query goes through a step of compilation – where the Linq query expression tree...
    May 27, 2021 2 min read
  • Productivity Testing

    Using the latest Web Testing Tools along with the latest RadControls

    Closely monitoring the customer feedback on our web testing tools, I noticed that various issues have actually been caused by outdated versions of the RadControls used along with the most recent testing tools versions. Please note that we highly recommend using the versions of RadControls and the testing tools from the exact same release. Let me explain why. I completely understand why customers do not always upgrade their applications with the latest RadControls (at least not immediately). “If it works, do not touch it” is a common principle. Of course that’s a matter of choice. However, as a ...
    May 27, 2021 3 min read
  • Productivity

    Tracing the SQL Statements Generated by Telerik OpenAccess ORM

    One of the main jobs that the ORM software should handle is communicating with the database server and generating SQL statements for reading and writing data. Undoubtedly, the performance of each application developed by using an ORM tool depends on the generated SQL. It is a responsibility of the ORM software to optimize each statement and avoid unnecessary queries. So, when you are facing a difficult choice of an O/R Mapper, it is always meaningful to see and compare how your data is treated by different products. However, not all database engines are distributed with additional profiling software for observing...
    May 27, 2021 3 min read