Monday, July 25, 2011

How to maintain the password textbox text after postback

Introduction

In this post I will explain how to maintain the password textbox text after postback. My previous post SQL Query to find Nth Highest or Lowest salary of an employee table.

Explanation

In Asp.net the password textbox will not remain the value after a postback happen, because the viewstate value will disappear. So for retaining the value in textbox control we have again reassign the value in viewstate.

Wednesday, June 29, 2011

Dynamic LinkButton Controls in Asp.Net

Introduction

In this post I will explain how to create and add dynamic table with dynamic link button in asp.net code behind. My previous post Error Logging in C# Asp.net.

Explanation

In the design page, we just add how many controls we need and where it should be placed. These controls are static and having the data what we gave. In some cases we have to dynamically get data from the database and create dynamic controls for the data.

Tuesday, June 28, 2011

Error Logging in C# Asp.net



Errors may occur during the development. Not only in the Web sites, it is in all the fields. Every coders may know which place the error will come.Some errors can be easily identified and get a solution easily.But some cases we cant identify what error and why this error is coming like this. For an good website we have to maintain the error log in the Application. So we can track the errors easily and fix the issues sooner.


In this post, we will see how to create a simple error log in our website. We will show an error has been occured message to the user. At the same time,we will log the error in a htm file. The html error file will be created with the name of current date. whenever the error is occurred, It will automatically update with the html file.

Saturday, January 30, 2010

Image uploading in Asp.net



Image uploading using Asp.net to MS sql server by c# is very easier.Here i will show how to convert an image to binary data and reduce the image size and then upload the binary data to MS sql server.

Create the Database structure

In the database we have to declare the image id, image name and image binary data.

name type
imageId int identity not null

Thursday, January 7, 2010

Captcha validation in Asp.net 2.0



Captcha validation in Asp.net 2.0.

Before Entering to topic first we must understand about the validation.Why most of the sites are validating the data's we entered.Like we gave a name with numeric values and special characters like.So these things are really wrong information by mistake wrongly typed.In email id most of the websites how they validate means they see the email id contains '@' followed with some words and having '.' symbol. So we have to give the informations correctly.

Monday, January 4, 2010

Basic Syntax in c# Language



A variable is a location in the memory that has a name and contains a value. Variable means the value can be changed. A variable name may contains ‘_’ (underscore) followed by a sequence of letters, digits(0-9), or underscores. The first character in a variable name cannot be a digit

//Variable Declaration
[data_type] [variable_name]=[value];

//Data types are two types.

Tuesday, September 22, 2009

How to send email in Asp.net c#



How to send email in Asp.net using c#. In Asp.net 2.0,email sending is very easy.In our websites we send a feedback,contact us,registration welcome,Forgot password, news letter etc. to the users mail.By using the Asp.net classes.
we can access to send the email.The Simple Mail Transfer Protocol(SMTP) server is used for deliver the mail
using the System.Net.Mail namespace.

Monday, September 21, 2009

how to get ip address using asp.net

How to get Internet protocol address using asp.net.Internet protocol is a communication between the nodes. Internet protocol, which is used to track a system host and used address the location. If we need to identify the user
who are all accessing our website and store the Internet protocol address in our database is very simple and very easier.

This is the way to track the users Internet protocol address.

Saturday, July 11, 2009

Connection String in Asp.net



Connection string in asp.net c#.In Asp.net there is an easier way give the Connection String.we can add more than one Connection String in the web.config file.Then we can access these Connection Strings in any of our Pages.This is a simply superb concept in Asp.net. for example,You have two
Connection Strings one for your local server and another one for your live server.You simply add these two Connections in the web.config file and access the first connection in one page and in another page you can use the next connection.

Monday, February 9, 2009

Gridview in asp.Net c#.

Dear folks, Welcome to dotnetpgm. This is my first post. This is a dotnet blog. I will share my work experience and ideas in Microsoft .Net Technologies.

Gridview in asp.net c# with sample

Grid view control in asp.net 2.0 is the replacement of Data grid in asp.net 1.1. Grid view is used to bind the data source. The whole database can be viewed in one gridview with colorful and formatted. We can easily view, edit, update and delete the data from this Grid view control. Default Paging is available in this Grid view control. In Asp.net grid view is a very simple and superb control. It reduce our work and perform good

Followers