473,554 Members | 2,921 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Check If Username Exsists

Hi,

just getting started on ASP.NET and C# and MS-SQL.

Ive managed to get all the connections working and database
intergrated nicely for content and stuff.

I now want to include a user registration form through a 4 step
process asking for various bits of info. I think I can get the data
passed one page to the next and then into the database when the user
presses confirm/register.

Problem I have is, how do I get the form to check the database to see
if the username already exsists ?

Any help appriciated as always.

H
Nov 17 '05 #1
1 1356
Be carefull not to confuse ASP.NET with traditional ASP.
In asp.net you don't need 4 separated pages, but only 1
web form and multiple panels that represent your
registration steps. This is the easiest way to do it.
Using 4 webform require passing data accross them, and
these are complications that you don't need (I'm not
saying is not possible, I'm just trying to avoid you
writting unnecesary code).

The right way to do the username validation, is to use a
CustomValidator control pointed to the control where the
user types the username.
-----Original Message-----
Hi,

just getting started on ASP.NET and C# and MS-SQL.

Ive managed to get all the connections working and databaseintergrated nicely for content and stuff.

I now want to include a user registration form through a 4 stepprocess asking for various bits of info. I think I can get the datapassed one page to the next and then into the database when the userpresses confirm/register.

Problem I have is, how do I get the form to check the database to seeif the username already exsists ?

Any help appriciated as always.

H
.

Nov 17 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
1591
by: Christina | last post by:
How can I do a simple asp check to verify if a physical file exsists on the server or not? Christina
0
1586
by: None | last post by:
Hi, I have written a c# code to find the given username and password is correct or not. (i.e the given username and password will be checked against the active directory) But i don't know how to check the username and password for WorkGroup machine. The difficulty i'm facing is that i don' know how to assign correct path to DirectoryEntry...
0
2120
by: Fossie | last post by:
Hi, I need to check that someone signing up is listed in an xml file. I am using a customer membership provider for Access and trying to integrate the xml check into that. Am I on the right track? The code below runs but it results in "Your account was not created. Please try again." It's obviously not picking up username and comparing it. ...
4
10186
by: Simon Gare | last post by:
Hi all, below is an insert statement on an asp page that stores the date and time that a driver logged on, what I need is to check that they are now already logged on fields are SQL Server 2000 ID int DRIVER_NO int
2
2669
by: dhyder | last post by:
I'm using ASP.Net 1.1 and C#. Testing DB is currently Access 2003. This is basically my code set-up: string checkUser = "SELECT * FROM customer WHERE username = " + tbUser.Text; if (query returns value) (<--- That is where my problem is) { lblError.Text = "That username is already taken." } else { INSERT info INTO DB
1
1409
uranuskid
by: uranuskid | last post by:
Hey folks, I was hoping someone could help me out with following problem: I want to use vSigup (available free at www.beanbug.net/vScripts.php) to manage protected pages. Well, that all works fine, however, I'd like to include a conditional clause on public pages where either a loginform is displayed or a Welcome user statement. The script...
3
1417
by: Nimion | last post by:
Sorry if I posted in the wrong forum, but since I'm looking at VB code I have a 50/50 chance at being wrong. :) I've been trying a variety of methods to speed up the checking for duplicates. Right now I'm using a simple while statement and if statement to go through the database row by row checking the field I want, and then moving onto the...
1
2144
by: chanshaw | last post by:
Hey I'm trying to see if a file exsists but I'm using windows, I know in Linux you can use -e but that doesn't seem to work for me in windows. if (-e $filename) { print "File Doesn't Exist!"; }
3
3674
by: PHPstarter | last post by:
Hiya. I have a script that is run by a <form> which basically allows u to write into inputs the fields username, new username, password, repeat password, comment etc, The problem is that I want the script to work in a way that, if a field, like the 'new username' has not been touched (no value), then the username wont be changed. The same...
0
7521
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language...
0
7889
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the...
0
6145
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then...
1
5436
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes...
0
5155
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert...
0
3560
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in...
0
3548
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
2020
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
1
1134
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.