Fabian1675
Registered User.
- Local time
- Yesterday, 21:31
- Joined
- May 5, 2011
- Messages
- 23
Hello; I have two forms one MainForm and StepChildForm and I have the following content on each form:
MainForm has a: ResultTextbox1 and ResultTextbox2 that I need to keep track of the entries from the StepChildForm.
StepChildForm has a: Textbox1; Textbox2; Textbox3; and Textbox4
base on user input I would like for what ever value (numeric) happens to be in Textbox3 to be outputed to either ResultTextbox1 Or ResultTextbox2
so if the user entered the following:
If Textbox1 = a and Textbox2 = a and Textbox3 = 2 and Textbox4 = a Then
ResultTexbox1 = Textbox3
Else:
ResultTextbox2 = Textbox3
So far I'm able able to accomphlish this as long as the user did not go back and changed the previous input.
The problem I encountered is when:
1) the user goes back and changed one of the Textbox input to say b the ResultTextbox2 will now = Textbox3, but the ResultTextbox1 still retains the previous data. What I would like is; since the If Statement is no longer True I want the ResultTextbox1 = 0
2) the other problem I encounter is if the user decided to add a second entry I would like the entries on both Textbox3 to be added and output the result to either ResultTextbox1 or ResultTextbox2
This is what I did to get the result to add up but It's not right:
ResultTextbox1 = (TextBox3) + (ResultTextbox1)
I guess my question is there a way to continously monitor the user input and reflect the changes into my ResultTextboxe(s) accordingly.
Thanks
MainForm has a: ResultTextbox1 and ResultTextbox2 that I need to keep track of the entries from the StepChildForm.
StepChildForm has a: Textbox1; Textbox2; Textbox3; and Textbox4
base on user input I would like for what ever value (numeric) happens to be in Textbox3 to be outputed to either ResultTextbox1 Or ResultTextbox2
so if the user entered the following:
If Textbox1 = a and Textbox2 = a and Textbox3 = 2 and Textbox4 = a Then
ResultTexbox1 = Textbox3
Else:
ResultTextbox2 = Textbox3
So far I'm able able to accomphlish this as long as the user did not go back and changed the previous input.
The problem I encountered is when:
1) the user goes back and changed one of the Textbox input to say b the ResultTextbox2 will now = Textbox3, but the ResultTextbox1 still retains the previous data. What I would like is; since the If Statement is no longer True I want the ResultTextbox1 = 0
2) the other problem I encounter is if the user decided to add a second entry I would like the entries on both Textbox3 to be added and output the result to either ResultTextbox1 or ResultTextbox2
This is what I did to get the result to add up but It's not right:
ResultTextbox1 = (TextBox3) + (ResultTextbox1)
I guess my question is there a way to continously monitor the user input and reflect the changes into my ResultTextboxe(s) accordingly.
Thanks
Last edited: