Showing posts from March, 2012

what is a static member of the Class in asp.net using c#

Static Members One of the tricks about .NET classes is that you really use them in two ways. You can use some class members without creating an object first. These are called static members, and they’re accessed by class name.

Foreach loop in asp.net using C#

In this web programming we will learn the use of foreach loop in C#. a foreach loop allows you to loop through the items in a set of data. With a foreach loop, you don’t need to create an explicit counter variable. Instead, you create a variable …

Inner Join in sql quey

In this web programming tutorial we will learn that how we can write sql query for Inner join see the below inner join query, SELECT * FROM Products INNER JOIN Suppliers ON Products.SupplierID = Suppliers.SupplierID

How to use IF Else Condition to show hide div using Jquery

In this Web Programming tutorial we will learn that how we can use IF and ELSE Condition in Jquery to show or Hide an element on a web form. below is the code: HTML Button Code: Below code will check if Div element is hidden than it will mak…

how to hide div on button click using jquery

In this JQuery web programming tutorial we will learn that how we can hide an element on a page using jquery. in this example we will learn that by clicking on a button how we can hide div or any element using jquery. HTML button JQuery Code $(…

how to add or replace css class on using jquery

In this web Programming tutorial we will learn that how we can replace or Add a css Class to take effect on a specific table's row using jquery, Css Class we want to replace .test { background-color: #dddddd; color: #666666; } Jquery Code to…

how to change Row back ground color and text color using jquery

In this web programming tutorial we will learn that how we can change the background color and text color of Table's alternate rows ie we want that Every "Even" Row's text color and background color of a table should changed using J…

how to reverse a string in asp.net using c#

In this web Programming tutorial we will learn that how we can print a string in reverse mode in asp.net using c#, for example you have a string as below string a = "ABCDEFGHIJKLMNOPQRSTUVWXYZ"; and you want to print or show it in Rever…

how to create image button dynamically in asp.net using c#

In this web programming tutorial we will learn that how we can creat a image button dynamically in asp.net using c#. See the below code for your .cs file in my case i have created a print button you may create a button as per your requirements. I…

how to format amount (Moany) in asp.net using c#

In this web Programming tutorial we will learn that how we can format a string to Monay type. see the below code in asp.net using c#. Code for .cs file Total_amount.Text = string.Format("{0:###,###,##0.00}", Total_Amountdue);

what is LINQ

LINQ (Language Integrated Query) is a set of extensions for the C# and Visual Basic languages. It allows you to write C# or Visual Basic code that manipulates in-memory data in much the same way you query a database. Technically, LINQ defines about…

how to save and fetch images from sql server in asp.net using c#

in previous article we explained that how to save files in sql server database using asp.net now we will learn that how to fetch images from sql server database in asp.net using c# below function in page load event will just fetch the image data fro…

how to convert text string into an image in asp.net using c#

in this web programming tutorial we will learn that how we can convert text string provided by user into an image in asp.net using c#. this will help us to make our own captcha images instead to use third party tools. HTML Code to get text string fr…

how to export data into excel file from grid view in asp.net using c#

In this web programming tutorial we will learn that how we can export grid view data into a pdf file in asp.net using c#. For exporting the GridView to PDF I am using the iTextSharp Library. You will need to Add Reference for the iTextSharp Library …

how to export grid view data into MS excel file in asp.net using c#

In this web programming tutorial we will learn that how we can export grid view data into MS excel file in asp.net using c# Code for .cs file protected void btnExportExcel_Click(object sender, EventArgs e) { Response.Clear(); Response.Buffer = true…

how to validate image at client side in asp.net

In this web Programming tutorial we will learn that how we can validate the image at client side before uploading it that it is according to our required format i.e. png, jpg or bmp. Upload a valid image;

how to re size the image while uploading in asp.net using c#

In this web programming tutorial we will learn that how can we resize the image while uploading to the server as per our requirements. code for .cs file using System; using System.Data; using System.Configuration; using System.Web; using Sys…

how to reset all form elements in asp.net using c#

In this web programming tutorial we will learn that how we can reset all web form controls in one click ie (by clicking on reset button) in asp.net using c#. code for .cs file. public static void ResetControls(ControlCollection pagecontrols, bool tx…

Javascript Validation in ASP.net

in this web programming tutorial we will learn that how we can validate asp.net form fields using javascript. See the below function and use it as per your requirements. function validateregform() { if (document.getElementById(" ").value…

how to Export Grid View Data into Excel in asp.net using c#

In this web programming tutorial we will learn that how we can export grid view's Data into an excel sheet in asp.net using c#. protected void BtnExport_Click1(object sender, ImageClickEventArgs e) { string attachment = "attachment; filenam…

how to Read and write text file in asp.net using c#

In this web programming tutorial we will learn that how we can read a text file in asp.net using c# and how we can write some text or data on a text file in asp.net using c#. Reading and writing (File manipulation) is a very easy task in asp.net, in…

how to Disable the text selection and drag and drop

in this web programming tutorial we will learn that how we can disable the drag and drop and text selection facility on our web pages. in order to do so just put the below code in body section of your code: but there is one drawback of the above cod…

how to check all check boxes using jquery

In this web programming tutorial we will learn that how we can check all check boxes in a page using jquery. Reason for Celebrity Famous on the internet Committed a crime Dates a super model Hosts a TV show Big in Japan Check all Jquery Code …

how to redirect page after some time delay in asp.net using c#

In this web programming tutorial you will learn how to redirect user after some time delay in asp.net using c#. Normally people use redirection process after showing some message to their users, for example a message can be "Thank you for visitin…

how to register DLL in asp.net

In this programming tutorial you will learn how to register dll. It is quite easy as you just have to execute a simple command, but before knowing the command you must have Administrator rights over the operating system (Windows). You just have to r…

how to call methods in asp.net using c#

In this web programming tutorial we will learn that how we can call or invoke our methods in asp.net using c#. Invoking your methods is straightforward—you simply type the name of the method, followed by parentheses. If your method returns data, you…

how to declare private method in asp.net using c#

In this web programming tutorial we will learn that how to declare a private method in asp.net using c#. When you declare a method in C#, the first part of the declaration specifies the data type of the return value, and the second part indicates t…

how to declare a method with return type in asp.net using c#

In this web programming tutorial we will learn that how to declare a method with return type in asp.net using c#. When you declare a method in C#, the first part of the declaration specifies the data type of the return value, and the second part ind…

how to declare methods in asp.net using c#

In this web programming tutorial we will learn that how we can declare methods in asp.net using c#. When you declare a method in C#, the first part of the declaration specifies the data type of the return value, and the second part indicates the met…

how to use Do while loop in asp.net using c#

in this web programming tutorial we will learn that how we can use do while loop in asp.net using c#. You can also place the condition at the end of the loop using the do . . . while syntax. In this case, the condition is tested at the end of each pa…

how to use The while loop in asp.net using c#

Finally, C# supports a while loop that tests a specific condition before or after each pass through the loop. When this condition evaluates to false, the loop is exited. int i = 0; while (i

how to use The for Loop in asp.net using c#

In this web programming tutorial we will learn that how we can use The for loop is a basic ingredient in many programs. It allows you to repeat a block of code a set number of times, using a built-in counter. To create a for loop, you need to specif…

how to use The switch Statement in asp.net using c#

In this web programming tutorial we will learn that how we can use switch statement in asp.net using c#. C# also provides a switch statement that you can use to evaluate a single variable or expression for multiple possible values. The only limitati…

how to use if Statement in asp.net using c#

The if statement is the powerhouse of conditional logic, able to evaluate any combination of conditions and deal with multiple and different pieces of data. Here’s an example with an if statement that features two conditions: if (myNumber > 10) { …

Operators in asp.net using C#

in this we programming tutorial we will know the list of operators in asp.net using c# Operator Description == Equal to. != Not equal to. <   Less than. >   Grea…

ASCII Character Codes for HTML

HTML Code Browser View HTML Code Browser View HTML Code Browser View HTML Code Browser View HTML Code Browser View &copy; © &#33; ! &#95; _ &#157;  &#219; Û &reg; ® &#34; " &#96; ` &#158; ž &#220; Ü &a…

how to restrict enter key using javascript

in this javascript web programming tutorial we will learn that how we can prevent Enter key to submit forms or perform any event in our web page. just copy and paste below java script in head section of you html page.

HTML Complete color codes list

Hexadecimal Value - #FFFFFF  RGB Color Code - R=255 G=255 B=255 #FFFFFF R=255 G=255 B=255 #FFFFCC R=255 G=255 B=204 #FFFF99 R=255 G=255 B=153 #FFFF66 R=255 G=255 B=102 #FFFF33 R=255 G=255 B=51 #FFFF00 R=255 G=255 B=0 #FFCCFF…

Load More
That is All