Aspdotnet-Suresh

aspdotnet-suresh offers C#.net articles and tutorials,csharp dot net,asp.net articles and tutorials,VB.NET Articles,Gridview articles,code examples of asp.net 2.0 /3.5,AJAX,SQL Server Articles,examples of .net technologies

Populate One Asp.net Dropdown based on Selection in Another Dropdown

Oct 31, 2010 61 comments
Introduction

Here I will explain how to populate one dropdown based on selection in another dropdown asp.net using c#.

Description

I have three dropdowns Country dropwdown, State dropdown, Region dropdown I need to populate states dropdown based on country dropdown and I need to populate region dropdown based on states dropdown for that what we have to do first design three tables in sql server with data like this 

Calculate age of person from date of birth using JavaScript

Oct 26, 2010 18 comments
Introduction

Here I will explain how to calculate age of person from date of birth and regular expression for mm/dd/yyyy format using JavaScript.

Description

In some situation we need to display age of person based on date of birth .In that situation we can calculate age of person using JavaScript by comparing present date and date of birth as shown below. Here I have a one textbox every time I need to validate that data whether user enter valid data or not if the date not in mm/dd/yyyy format or not.
Regular expression for mm/dd/yyyy date format is

re=/^(0[1-9]|1[012])[- /.](0[1-9]|[12][0-9]|3[01])[- /.](19|20)\d\d+$/;

If you want to implement code for calculate age of person using javascript design your aspx page like this

Registration form example to insert user details in database using asp.net

Oct 24, 2010 74 comments
Introduction

Here I will explain how to insert registered user details in database and how to get output parameters returned by SQL Query in asp.net.

Description

I have one registration form that give a chance to register new user .In registration form user needs to enter fields UserName, Password, Confirm Password like this I have nearly ten fields are there now I need to check whether this username already exists or not if username not exists I need to register user otherwise I need to display message like username already exists I am doing this thing using query. Here is the link it will explain how to write sql query to return output parameters 

how to display Good Morning,Good Afternoon and Good Evening Messages based on time in asp.net

Oct 22, 2010 7 comments
Introduction

I will explain how to display Good Morning,Good Afternoon and Good Evening Messages based on time in asp.net

Description

In some of websites we will see greeting messages like good morning, good afternoon and good evening messages how to display those messages in our website. Basically those messages will display by calculating present time and we can display that greeting messages.

For that first design your aspx page like this  

Javascript validations for Email,Phone no and allow only characters, spaces, numbers in asp.net

17 comments
Introduction 

Here I will explain how to validate Email,phone number,to allow only characters and spaces and for allow only numbers using JavaScript validations in asp.net.

Description

I have a one sample registration form that contains fields like Name, Email, PhoneNo .
Now I want to check whether user enter correct email format or not, and phone number contains only numbers or not and name contains only characters and spaces or not by using JavaScript.

Here some of commonly used regular expressions

Javascript validations to validate form in asp.net

10 comments
Introduction 

Here I will explain how to validate form using JavaScript validations in asp.net 

Description

I have a one sample registration form that contains fields like Username, Password, Confirm Password, First Name, Last Name, Email, PhoneNo and Location.
Now I want to check whether user enter data in all fields or not and I want to check whether user enter correct data in all fields or not by using JavaScript.

If I want to check whether user enters data in textbox or not write script like this 

Stored procedure with output parameter in sql server

Oct 19, 2010 37 comments
Introduction:

Here I will explain how to write query to return output parameters in SQL Server.

Description:

In some situations we need to return the output value after execution of our query here I will explain with simple user registration here I am returning one out parameter if the query executes successfully else I am returning another output parameter .

SQL Server - Move Data from One Database Server to Another Database Server

Oct 14, 2010 3 comments
Introduction

Here I will explain how to transfer or copy or move data from one server database table to another server database table in SQL Server.

Background

I created one table Addresstype in database1 in server1 with some data. I have created same table Addresstype with same columns in database2 in server2. Now I want to fill AddressTpe table in server2 with data of Addresstype in server1.

Cannot open database requested by the login. The login failed. Login failed for user 'NT AUTHORITY\NETWORK SERVICE'.

Oct 6, 2010 15 comments
Introduction

Here I will explain about my database connection error in SQL Server if trying to get data by using asp.net.

Description

I have created one database in my Local SQL Server Management Studio in that I created one table and entered some data in that table.

Asp.net set session timeout in web.config IIS

Oct 2, 2010 12 comments
Introduction:

Here I will explain how to set session timeout in web.config,IIS and in application using asp.net manually.

Description:

By default our websites session timeout is 20 mins after that session will gets expire suppose if we want to set our custom timeout in our applications we can set it in different ways (web.config, global.asax and in IIS)
© 2015 Aspdotnet-Suresh.com. All Rights Reserved.
The content is copyrighted to Suresh Dasari and may not be reproduced on other websites without permission from the owner.