Skip to main content

Posts

Showing posts from 2012

ReportViewer Toolbar with Style Sheet

Microsoft Reporting Services for web provides default cascading style sheets (.css) files that is embedded and defines styles for the report toolbar in HTML Viewer and Report Manage. If you want to customize the report toolbar as your own styled control like your own color, font and layout of items, you must be struggling to adjust style sheet for reportviewer. In the meantime a web developer are working on css file, sometimes faces with weird situation seeming never revealing why stupid error happens after it perfectly worked. After publishing an web application to an IIS 7.0 server, The Toolbar which worked nicely is completely broken and showed up something like this,

ASP.NET 4.0 with Ajax

It's common for an web application to retrieve data from server and bind to control. Control being alone without data binding is nothing more than styled modeling statue. So interacting between DB and web control comes to challenge for developers whenever we design its working procedure. Ajax is possible only with a strong JavaScript engine that runs within the client browser and provides the foundation for more advanced and asynchronous features. The Javascript library currently incorporated in ASP.NET 3.5 Service Pack 1 is a necessary, but insufficient, attempt to deliver such a library. A more powerfule ASP.NET AJAX platform is required and it is just being introduced as part of ASP.NET AJAX 4.0 Requirements for Client-Side Data Binding There are two fundamental patterns for implementing data binding functionalities. One is the HTML Message pattern, and the other is the Browser-side Template pattern. The former entails making a remote service call to a component that re...

SQL Server 2008 Merger Statement

The most challenging issue of using SQL jobs to updating procedure is to check unique data with relative table. If you are using SQL Server 2005 or below you would have to write a series of T-SQL statements that check to see if the record exists, and then write an UPDATE or INSERT statement depending on your existence checks. SQL Server 2008 introduced the Merge statement which is commonly also called as Upsert (Update / Insert). It can be used as Insert if the row does not exists and update, if it exists. It can be used as ETL process while fetching data. This feature is useful for developers. It is not required to give any particular join (inner, left outer etc). Here are a few facts that you must know before starting to use Merge Statement: Atomic statement combining INSERT, UPDATE and DELETE operations based on conditional logic Done as a set-based operation; more efficient than multiple separate operations MERGE is defined by ANSI SQL; you will find it in other databa...

Javascript and Touch devices.

If you are working on draggin and dropping some stuffs on html, you must be aware of whether it still works on mobile devices which support touch function. Maybe you could consider using JQuery UI plugin which allows "droppable" elements. jQuery Plugin Or here is another descent plugin iPhone Touch Touch Event for webkit touchstart - triggered when a touch is initiated. Mouse equivalent - mouseDown touchmove - triggered when a touch moves. Mouse equivalent - mouseMove touchend - triggered when a touch ends. Mouse equivalent - mouseUp. This one is a bit special on the iPhone - see below touchcancel - bit of a mystery Example docuement.addEventListener('touchstart', function(event) { event.preventDefault(); var touch = event.touches[0]; alert("Touch x:" + touch.pageX + ", y:" + touch.pageY); }, false); IPhone Touch and Gesture Events Apples WebKit implementation has a few things that are different from the Android implement...

HTML5 Canvas Painting

This is my very first post at my first blog so I am now really exciting.  I am not sure how long I could keep this blog updated but there is a saying Beginning goes half of the way..(= Well beginning is half done). OK let's get it cracked. HTML 5 Canvas - Painting Making a web application that allows users to draw on a canvas requires several important steps: setting up your HTML document with a canvas context (a canvas element with an id ), setting up your script to target that canvas context and draw inside it and adding the required mouse event handlers for user interaction and associated logic. Once the event handlers are in place, it's then fairly simple to add any desired functionality. My goal of this article is to import image into canvas then to edit it with several painting tools and to end up saving as another format. We shall begin with a minimal HTML document: <html lang="en"> <head meta charset="utf-8"...