View Single Post
12-21-2007, 12:04 AM
Bursh. is offline Bursh.
Status: Member
Join date: Nov 2006
Location: In your bath.
Posts: 121
iTrader: 0 / 0%

Bursh. is on a distinguished road

Send a message via AIM to Bursh. Send a message via MSN to Bursh.

  Old  [ASP.NET\VB] User exists

OK. So i'm dealing with the ASP.NET membership systems right now and i'm writing a page for activating a user based on the code and the username supplied in the querystring.

What I need to do is check to see if the username supplied exists in the users table.

There only way I can think to do this, is get a collection of all the users in the database, and see if it's in the collection. 2 problems with that though:
  1. I don't know how to do that (yet)
  2. It will be really slow when the database gets bigger
Is there any other way to do it? And could somebody show me how to check if something is(or in this case isn't) in a collection using an if statement (I want to do "If value isn't in collection, do error page")?