tag:blogger.com,1999:blog-56022637604917857582009-07-06T23:22:42.659-07:00DevArchive.net BlogKirill Chilingarashvilihttp://www.blogger.com/profile/09906215698720468631noreply@blogger.comBlogger37125tag:blogger.com,1999:blog-5602263760491785758.post-15391858405200352942008-12-14T13:20:00.001-08:002008-12-14T13:28:00.559-08:00Simplify Inline Editing using GridView, GridViewControlEmbedder ASP.NET AJAX Extender.I created another nice ASP.NET AJAX extender for GridView. With it's help you can enable inline editing for Grids in web pages relatively faster, comparing to time needed to implement this feature from scratch using pure JavaScript. For example having the following GridView on the page: You can add an extender that allows editing of values of cells right in place: Extender has inner Kirill Chilingarashvilihttp://www.blogger.com/profile/09906215698720468631noreply@blogger.com3tag:blogger.com,1999:blog-5602263760491785758.post-58554622169159787972008-11-09T11:05:00.001-08:002008-11-11T12:43:38.448-08:00Code generation technique using MS codename "Oslo", T4 templating engine and VS Custom toolYou can download full source code for this post here. Not long time ago Microsoft announced new product named "Oslo". Quote from Microsoft Oslo Developer Center: "Oslo" is the code name for our platform for model-driven applications. The goal of "Oslo" is to provide a 10x productivity gain by making model-driven applications mainstream with domain-specific models, a new language, and tools.Kirill Chilingarashvilihttp://www.blogger.com/profile/09906215698720468631noreply@blogger.com3tag:blogger.com,1999:blog-5602263760491785758.post-1008939751724096682008-08-26T11:16:00.001-07:002008-08-26T21:53:58.452-07:00Auto Generate References for Controls Residing in Naming Containers, ASP.NETCurrently I work on a big project with quite a big amount of UserControls in it. Many controls in the system have quite complex markup. And often I need to reference controls residing in the naming containers, or simply inside another controls. for example if you have the markup like this: you cannot simply reference control name rb1 or rb2 from the code behind of that control. So I use Kirill Chilingarashvilihttp://www.blogger.com/profile/09906215698720468631noreply@blogger.com0tag:blogger.com,1999:blog-5602263760491785758.post-71004949714941758102008-05-12T13:12:00.001-07:002008-05-12T13:38:28.892-07:00Loading and Executing JavaScript Files From JavaScript, ASP.NET AJAXDownload source code with samples for the article here. Quite often we need to load js files dynamically right from javascript. With ASP.NET AJAX it is simple. ASP.NET AJAX library has internal ScriptLoader class that can be used to load js files, specify callbacks that will be invoked when script is downloaded and ready, and execute functions inside newly loaded files. I will not list all Kirill Chilingarashvilihttp://www.blogger.com/profile/09906215698720468631noreply@blogger.com0tag:blogger.com,1999:blog-5602263760491785758.post-38664252354175497812008-05-12T08:53:00.001-07:002008-05-12T11:38:30.333-07:00Using AjaxRepeater Control, ASP.NET AJAXYou can download full source code with samples and controls for the article here. Recently after reading blog post Ajax Templates by Nikhil Kothari I really liked the idea, the source code is great, and the control is huge help for AJAX development. In this blog post I want to share what I learned after investigating sample more carefully, and in what scenarios I feel this control is doing it'sKirill Chilingarashvilihttp://www.blogger.com/profile/09906215698720468631noreply@blogger.com3tag:blogger.com,1999:blog-5602263760491785758.post-71174617626839977632008-05-03T14:21:00.001-07:002008-05-03T14:57:53.700-07:00Cross Browser GridView Fixed Header Extender, ASP.NET AJAXI have created ASP.NET AJAX Extender control. It extends GridView control fixing it's header on the top while adding vertical scroll bar to it's contents. The control also supports maintaining scroll position inside grid between postbacks. The control works fine inside or outside of UpdatePanel. To extend GridView, just drop extender onto the design surface and set its TargetControlID: Width Kirill Chilingarashvilihttp://www.blogger.com/profile/09906215698720468631noreply@blogger.com14tag:blogger.com,1999:blog-5602263760491785758.post-53073945572827377812008-04-15T11:43:00.001-07:002008-04-15T11:53:50.977-07:00Using #region Directive With JavaScript Files in Visual StudioSuppose how nice it would be to use #region directive when writing javascript code. Javascript is becoming more and more complicated, and it is hard to scroll up and down every time we want to find needed function name and see what parameters it accepts. I was so tired with this scrolling that started to search some alternative small IDE-s or highlighting text editors which would allow me to Kirill Chilingarashvilihttp://www.blogger.com/profile/09906215698720468631noreply@blogger.com16tag:blogger.com,1999:blog-5602263760491785758.post-55073231263530910662008-04-13T02:39:00.001-07:002008-04-13T03:08:38.450-07:00Advanced Tooltip Control, ASP.NET AJAXYou can download source code only for control, sample page with control, or see the sample online. I have created Tooltip control that replaces standard browsers' tooltips with custom ones. You can write your own html template to customize it's look and feel. The control derives on the client from Sys.UI.Control, and is implemented as WebControl on the server. It is really easy to use it and Kirill Chilingarashvilihttp://www.blogger.com/profile/09906215698720468631noreply@blogger.com32tag:blogger.com,1999:blog-5602263760491785758.post-29001488808243792312008-04-10T13:03:00.001-07:002008-04-10T13:19:33.280-07:00Nice Visual Studio SkinI never tried to use any skins with my Visual Studio dev environment before. After watching several screen casts from Rob Conery I wished to change my IDE a little and find theme similar to what I've seen in webcast. After a little search I found download link on http://codeclimber.net.nz, post: Pimping my Visual Studio. Yes, :) I like the theme :P, here is the screen shot of my working Kirill Chilingarashvilihttp://www.blogger.com/profile/09906215698720468631noreply@blogger.com6tag:blogger.com,1999:blog-5602263760491785758.post-69320101021401947292008-04-09T15:16:00.001-07:002008-04-10T12:30:21.093-07:00Client Side Timer Component, ASP.NET AJAXYou can download source code for control only, sample with control, and see the sample online. We can use server side timer control that is available in AJAX library. But often we need timer that works on client only. Server Timer control posts back every time when tick event is raised. I need the similar control, that raises this event on client. I found one very good sample, and to not wasteKirill Chilingarashvilihttp://www.blogger.com/profile/09906215698720468631noreply@blogger.com2tag:blogger.com,1999:blog-5602263760491785758.post-10616953300065218822008-04-07T12:04:00.001-07:002008-04-07T12:08:44.001-07:00White Spaces in HTML Source - Be CarefulHmm, Interesting. I am going to show you a very interesting figures about white spaces in HTML source of our ASP.NET pages. I was a little puzzled when I saw this figures and understood that there is no optimization or something in IIS that removes or somehow optimizes this thing. Suppose we have a page with a following markup: <%@ Page Language="C#" AutoEventWireup="true" CodeFile="Kirill Chilingarashvilihttp://www.blogger.com/profile/09906215698720468631noreply@blogger.com3tag:blogger.com,1999:blog-5602263760491785758.post-78113208536845155642008-04-06T14:13:00.000-07:002008-04-06T13:26:16.341-07:00Using IScriptControl interface with UserControls in ASP.NET AJAX Applications.Often we need to write some custom AJAX component that will serve UserControl, and will define some client side functionality that is specific only to that UserControl. OK we can find a samples in the AJAX docs covering how to create custom inheritor from Sys.Component or Sys.UI.Control or Sys.UI.Behavior classes in javascript part of AJAX framework. We can also find how to create custom Kirill Chilingarashvilihttp://www.blogger.com/profile/09906215698720468631noreply@blogger.com0tag:blogger.com,1999:blog-5602263760491785758.post-79985761118129029292008-04-03T15:01:00.001-07:002008-04-03T15:01:16.757-07:00StateBag Control - Simplifying Data Exchange in Heavy AJAX Pages - Sample Source Code Part 2You can download code for this article or see it live. Also you can download source code for StateBag control only. This is second post with samples in a series of articles about exchanging complex objects between different parts of AJAX enabled page. You can see the whole article by following these two links: StateBag Control - Simplifying Data Exchange in Heavy AJAX Pages StateBag Kirill Chilingarashvilihttp://www.blogger.com/profile/09906215698720468631noreply@blogger.com0tag:blogger.com,1999:blog-5602263760491785758.post-84318323454770593812008-03-30T18:47:00.001-07:002008-04-03T15:06:46.947-07:00StateBag Control - Simplifying Data Exchange in Heavy AJAX Pages - Sample Source Code Part 1You can download code for this article or see it live. Also you can download source code for StateBag control only. This is second part of article that was started here. I will start with smaller samples. First lets create simple page with UpdatePanel on it and leverage our state control to save and send to server some client side state. In the sample I will use google charts API to create Kirill Chilingarashvilihttp://www.blogger.com/profile/09906215698720468631noreply@blogger.com0tag:blogger.com,1999:blog-5602263760491785758.post-16123247251770709732008-03-29T17:59:00.001-07:002008-04-05T03:20:31.671-07:00StateBag Control - Simplifying Data Exchange in Heavy AJAX PagesDownload source code View samples live: Sample 1 Sample 2 Using standard ASP.NET postback model, browser sends data to the server using QueryString and Form objects. If we look farther, ASP.NET has state persistence mechanism known also as ViewState, which uses simple hidden input to store the state data. Every time we make postback - the value of that hidden input is send with Kirill Chilingarashvilihttp://www.blogger.com/profile/09906215698720468631noreply@blogger.com0tag:blogger.com,1999:blog-5602263760491785758.post-15802575600573513092008-03-29T14:30:00.001-07:002008-03-30T06:53:58.527-07:00Creating Custom Auto Complete Content Loading Functionality Using ASP.NET AJAXYou can download the source code for this article, or see it live. As more developers move to AJAX and start using it's controls, I noticed - the more they are bound to AjaxControlToolkit controls. Often I can see they use AjaxControlToolkit controls in places where it is not needed at all, sometimes, in places where the problem could be solved more efficiently, using very simple script. I wantKirill Chilingarashvilihttp://www.blogger.com/profile/09906215698720468631noreply@blogger.com1tag:blogger.com,1999:blog-5602263760491785758.post-58923528333388010502008-03-09T11:36:00.001-07:002008-03-09T11:39:49.740-07:00JavaScript Enumerations in ASP.NET AJAX FrameworkWith AJAX "revolution" last years we write more and more complicated javascript code. Using enumerations can significantly improve the quality of client-side code and make it more readable. In this post I will show some code samples describing how to create and use enumerations in ASP.NET AJAX framework. So how can we create and use enumerations in ASP.NET AJAX framework. The simplest Kirill Chilingarashvilihttp://www.blogger.com/profile/09906215698720468631noreply@blogger.com0tag:blogger.com,1999:blog-5602263760491785758.post-48323084809616747932008-03-03T18:20:00.001-08:002008-03-03T18:20:15.988-08:00Executing method in the class library using ASP.NET AJAX with no WebService or PageMethod call - Part2.This post covers second part of my investigations in how we can execute some class library method remotely from javascript without using WebService call or PageMethod call. First part of the article is available on this link. Saying shortly I created assembly that needs minimum configuration to redirect call to any class library referenced in the web site ! I placed source code on my website - Kirill Chilingarashvilihttp://www.blogger.com/profile/09906215698720468631noreply@blogger.com2tag:blogger.com,1999:blog-5602263760491785758.post-17098684773124459802008-03-02T14:35:00.001-08:002008-03-03T18:22:05.522-08:00Executing method in the class library using ASP.NET AJAX with no WebService or PageMethod call - Part1.Download source code for this article. Second part of the article is available here. In my current project I need to cleanly separate logic of some API that resides in class library project from web sites that will use it. If I use standard approach - to call server methods from javascript code - I have only two options: WebService call or PageMethod call. But I don't want to configure each Kirill Chilingarashvilihttp://www.blogger.com/profile/09906215698720468631noreply@blogger.com0tag:blogger.com,1999:blog-5602263760491785758.post-3571899511958497222008-02-25T13:43:00.001-08:002008-02-25T14:02:16.042-08:00Attaching custom client-side data to ASP.NET AJAX WebRequest objects.Often we need to store some client-side data from request to request. Because the browser supports two simultaneous connections to the server it's easy to do two concurrent requests to the server - and when response is received we want to somehow differentiate between that requests. For example when I click on Button1 - I want to pass let's say exact time when request was invoked, or some Kirill Chilingarashvilihttp://www.blogger.com/profile/09906215698720468631noreply@blogger.com0tag:blogger.com,1999:blog-5602263760491785758.post-88281984241968003582008-02-20T17:28:00.001-08:002008-02-20T17:28:47.053-08:00Creating update progress indicator for AJAX enabled applications that blocks user interface while updatingThis is quite needed and required thing - have a good progress indicator that the same time blocks whole screen to prevent sending several simultaneous asynchronous requests to the server. So I decided to place a code that I currently use. Actually this code is a synthesis of codes I already have seen in some blog posts in the Internet, but it is customized to my current needs. The indicator Kirill Chilingarashvilihttp://www.blogger.com/profile/09906215698720468631noreply@blogger.com10tag:blogger.com,1999:blog-5602263760491785758.post-84800318020846825642008-02-19T12:28:00.001-08:002008-02-19T12:35:30.737-08:00Implementing IDIsposable Interface In JavaScript Class Using ASP.NET AJAX Library.Are you so happy to already know what memory leaks can do with a browser? Did you learn how to subscribe to document's events to release resources you used in javascript class? If you use ASP.NET AJAX, it gives a couple of good ways of handling scripts that need cleanup operation. What is cleanup? Ok, javascript is not ideal environment to develop large code bases. There is garbage collector Kirill Chilingarashvilihttp://www.blogger.com/profile/09906215698720468631noreply@blogger.com0tag:blogger.com,1999:blog-5602263760491785758.post-84172792498982740712008-02-07T15:09:00.001-08:002008-02-24T00:19:58.084-08:00Auto generate release scripts for web application using T4 templateDownload source code for this article. New version of VS 2008 supports advanced intellisense features, and this is definitely good. I think you are aware of this fact, if not read ScottGu's perfect article first. Intellisense also takes care of displaying associated comments of a js functions Take a look: With these enhancements developers are encouraged to comment every javascriptKirill Chilingarashvilihttp://www.blogger.com/profile/09906215698720468631noreply@blogger.com1tag:blogger.com,1999:blog-5602263760491785758.post-49633200737489464352008-02-01T16:31:00.001-08:002008-02-01T16:37:51.505-08:00Using "DHTML Calendar" with ASP.NET AJAXYesterday I lost 2 hours of my life trying to find why AJAX client library function "Date.parseInvariant(value, format)" does not work. This is a beautiful function allows us to convert strings into Date objects in javascript. It allows us to specify exact format of a string in .NET way. For example: Date.parseInvariant("01/12/2008", "dd/MM/yyyy") will return valid date pointing to 1st of Kirill Chilingarashvilihttp://www.blogger.com/profile/09906215698720468631noreply@blogger.com2tag:blogger.com,1999:blog-5602263760491785758.post-4140926969372470272008-02-01T15:36:00.001-08:002008-02-02T02:31:13.461-08:00Serializing DateTime values using JavaScriptSerializer class.I use this class intensively in my current AJAX-enabled web application. The class serializes/deserializes C# class into JSON, and can deserialize it back. To see more details about the class you can see my previous post: Passing complex objects between client browser and web server using ASP.NET AJAX framework or official ASP.NET AJAX documentation. I have the problem with correct Kirill Chilingarashvilihttp://www.blogger.com/profile/09906215698720468631noreply@blogger.com1