To avoid duplicates in a text file.

indraja

New member
Joined
Jun 18, 2007
Messages
3
Programming Experience
Beginner
Hi Everyone.

Iam working on vb.net windows application.Iam inserting User Name and Pass word in to a text file.Now i want to avoid duplicate user names into the text file ,so how can i check the entered user name exists or not .If it exists then get a message that the User Name already exists.


I have a text file where in the data is

indoo;indoo;Admin

indraja;indraja;User



Now i want is if i enter user name as "indoo" again i have to get a message user name already exists.



Please its very Urgent.

Help me.
 
I would use ArrayLists to store the user names and passwords and a listbox or combobox to show the user names

When using ArrayLists you can use the .Contains() to see if it's already on the list or not
 
Back
Top