Wednesday, February 13, 2013

Upload and Read the Excel file using C#

This example will show you how to Upload the excel file and then read the excel file data using C# and display it on Gridview.

Drag and drop the FileUpload control and Button control from toolbox. Also drag and drop the Gridview  control for display the excel file data. ASPX page will look as following.

Friday, February 8, 2013

Bind Multiple Controls to a Single Event in jQuery

In this sample, we will see how to bind Multiple Controls to a single event in jQuery. We will bind 5 button controls (Button A, B, C, D and E) to a single click event. This example also demonstrates how to create an array of controls and loop through them. Here’s the sample:

Thursday, February 7, 2013

Simple script to backup all SQL Server databases

Working as developer or DBA, we often required to take the backup of database. This is not a big deal if you have a handful of databases, but this task become very hectic if the there is number of databases (ex. 50+) on the same instance of SQL Server. You could use SQL Server Management Studio to backup the databases or even use Maintenance Plans, but using T-SQL is a much simpler and faster approach.

Wednesday, February 6, 2013

Disable cut, copy and paste in textbox using jquery, javascript

Sometimes we need to restrict the user to cut or copy the content from TextBox and also restrict to paste the content into TextBox. It is very easy to do this using Java Script as well as using Jquery. Here I will show you both the methods i.e. using Java Script and using jQuery.

Friday, February 1, 2013

Nested Gridview with Expand/Collapse Functionality

Here in this example, I am going to show you how to create Nested Gridview with Expand and Collapse Functionality.

I have used java script to add the expandable and collapsible functionality in nested gridview by displaying plus and minus image. I have used Subjects and SubjectUnits tables to populate the nested gridviews. 
^ Scroll to Top