You are viewing our Forum Archives. To view or take place in current topics click here.
Help fix this simple c# issue
Posted:
Help fix this simple c# issuePosted:
Status: Offline
Joined: May 15, 201113Year Member
Posts: 1,543
Reputation Power: 65
Status: Offline
Joined: May 15, 201113Year Member
Posts: 1,543
Reputation Power: 65
Essentially I am only starting to seriously get into programming after a short placement with a massive software development company so I am definitely not well educated as you will be able to tell by the image you are about to see (i felt it was fitting to put it in so it could help show what i am tying to do as i am probably not going to explain this well).
Firstly i attempted to pull the usernames and passwords from a database using some code i found on the internet which did not work and then wasted my time as i tried to find fixes online and try to modify it myself. Im leaving that for now but i want a temporary log in screen to help test and add new features so i have attempted a method of using the text input into the textbox and comparing it to a username or password directly. Unfortunately i am so new to this i do not know the function for this or if it is possible but by what you can see below i attempted it using bool and int which obviously wouldnt work.
Is there a way i can redo some of this (probably most of it) in order to get what i want working until i have the database linked properly in the future?
Firstly i attempted to pull the usernames and passwords from a database using some code i found on the internet which did not work and then wasted my time as i tried to find fixes online and try to modify it myself. Im leaving that for now but i want a temporary log in screen to help test and add new features so i have attempted a method of using the text input into the textbox and comparing it to a username or password directly. Unfortunately i am so new to this i do not know the function for this or if it is possible but by what you can see below i attempted it using bool and int which obviously wouldnt work.
Is there a way i can redo some of this (probably most of it) in order to get what i want working until i have the database linked properly in the future?
#2. Posted:
Status: Offline
Joined: Dec 30, 201211Year Member
Posts: 3,778
Reputation Power: 3016
Status: Offline
Joined: Dec 30, 201211Year Member
Posts: 3,778
Reputation Power: 3016
First of all, why are you trying to parse a string to an int? It would be easier for you to just set it as a string and have inUser = tbUser.Text.
- 4useful
- 0not useful
#3. Posted:
Status: Offline
Joined: May 15, 201113Year Member
Posts: 1,543
Reputation Power: 65
Status: Offline
Joined: May 15, 201113Year Member
Posts: 1,543
Reputation Power: 65
Liability wrote First of all, why are you trying to parse a string to an int? It would be easier for you to just set it as a string and have inUser = tbUser.Text.
I dont know if i am doing something incredibly wrong but it is telling me i cant do that
- 0useful
- 0not useful
#4. Posted:
Status: Offline
Joined: Dec 30, 201211Year Member
Posts: 3,778
Reputation Power: 3016
#5. Posted:
Status: Offline
Joined: May 15, 201113Year Member
Posts: 1,543
Reputation Power: 65
Status: Offline
Joined: May 15, 201113Year Member
Posts: 1,543
Reputation Power: 65
You are viewing our Forum Archives. To view or take place in current topics click here.