I have made a VB console application. I can add names to a list on a TXT file.I can then set it up so
If input = input Then
objwriter = new streamreader("\users" input ".txt")
strcontents = objreader.readtoend
objreader.close()
console.clear
console.homepage
Which will work if the input is the name of the text file. But if i put something in incorrect then the whole program crashes.
I guess my question is, is there a way of making it check the obj writer, and if it doesn't match then say "incorrect user please try again".
Any ideas would be grateful.
Aucun commentaire:
Enregistrer un commentaire