Paging Computer Programmers, visual baqsics, etc

LOL. Let me guess you doing that VB book with the guided program development?

Anyways what you need to do is create the gui using something like a radio button. Create a case statement for each radio button. For example it should be something for Case radAdditionChoice.checked = true THEN variable1 + variable2

you will need the user to input both variables via a textbox and pull the data from the textbox into a variable

if you need more help i can go into better detail but basically just use a case statement.
 
LOL. Let me guess you doing that VB book with the guided program development?

Anyways what you need to do is create the gui using something like a radio button. Create a case statement for each radio button. For example it should be something for Case radAdditionChoice.checked = true THEN variable1 + variable2

you will need the user to input both variables via a textbox and pull the data from the textbox into a variable

if you need more help i can go into better detail but basically just use a case statement.
 
I had to do this in my VB class last year and I was pretty good at it. But now that I havnt used it since then i forgot how to do everything
tired.gif
 
I had to do this in my VB class last year and I was pretty good at it. But now that I havnt used it since then i forgot how to do everything
tired.gif
 
What I use to do was have 3 text boxes and a "Calculate" button
1st 2 text boxes are for the numbers 3rd is for the answer

I would declare all three such as

Dim NumberOne, NumberTwo, Answer as Integer

NumberOne = TextBox1.Text
NumberTwo=TextBox2.Text
Answer=Textbox3.Text

NumberOne - NumberTwo = Answer

my syntax is prob wrong because I havent done this in a few months, but along the lines of that
 
What I use to do was have 3 text boxes and a "Calculate" button
1st 2 text boxes are for the numbers 3rd is for the answer

I would declare all three such as

Dim NumberOne, NumberTwo, Answer as Integer

NumberOne = TextBox1.Text
NumberTwo=TextBox2.Text
Answer=Textbox3.Text

NumberOne - NumberTwo = Answer

my syntax is prob wrong because I havent done this in a few months, but along the lines of that
 
Originally Posted by 4318MichaelJohnson4318

LOL. Let me guess you doing that VB book with the guided program development?

Anyways what you need to do is create the gui using something like a radio button. Create a case statement for each radio button. For example it should be something for Case radAdditionChoice.checked = true THEN variable1 + variable2

you will need the user to input both variables via a textbox and pull the data from the textbox into a variable

if you need more help i can go into better detail but basically just use a case statement.


Something like this:variable1 = textbox1.valuevariable2 = textbox2.valueIf radAdditionChoice.value = true then answer= variable1 + variable2elseif radSubtractionChoice.value = true then answer = variable1 - variable2end ifBTW, this is in vba.
 
Originally Posted by 4318MichaelJohnson4318

LOL. Let me guess you doing that VB book with the guided program development?

Anyways what you need to do is create the gui using something like a radio button. Create a case statement for each radio button. For example it should be something for Case radAdditionChoice.checked = true THEN variable1 + variable2

you will need the user to input both variables via a textbox and pull the data from the textbox into a variable

if you need more help i can go into better detail but basically just use a case statement.


Something like this:variable1 = textbox1.valuevariable2 = textbox2.valueIf radAdditionChoice.value = true then answer= variable1 + variable2elseif radSubtractionChoice.value = true then answer = variable1 - variable2end ifBTW, this is in vba.
 
i don't know how to program, but learning is no problem, where should i start.
I talked to my cousin in law, whos a math teacher, she told me to write out an algorithm, and that is done.
where should i get the knowledge, what language, C, C+, C++?
i just got Visual Studio, I guess i'm ready.
 
i don't know how to program, but learning is no problem, where should i start.
I talked to my cousin in law, whos a math teacher, she told me to write out an algorithm, and that is done.
where should i get the knowledge, what language, C, C+, C++?
i just got Visual Studio, I guess i'm ready.
 
Originally Posted by LuckyLuchiano

What I use to do was have 3 text boxes and a "Calculate" button
1st 2 text boxes are for the numbers 3rd is for the answer

I would declare all three such as

Dim NumberOne, NumberTwo, Answer as Integer

NumberOne = TextBox1.Text
NumberTwo=TextBox2.Text
Answer=Textbox3.Text

NumberOne - NumberTwo = Answer

my syntax is prob wrong because I havent done this in a few months, but along the lines of that
This. I sometimes also use a label for the answer.
 
Originally Posted by LuckyLuchiano

What I use to do was have 3 text boxes and a "Calculate" button
1st 2 text boxes are for the numbers 3rd is for the answer

I would declare all three such as

Dim NumberOne, NumberTwo, Answer as Integer

NumberOne = TextBox1.Text
NumberTwo=TextBox2.Text
Answer=Textbox3.Text

NumberOne - NumberTwo = Answer

my syntax is prob wrong because I havent done this in a few months, but along the lines of that
This. I sometimes also use a label for the answer.
 
Originally Posted by gregbutler20

Originally Posted by LuckyLuchiano

What I use to do was have 3 text boxes and a "Calculate" button
1st 2 text boxes are for the numbers 3rd is for the answer

I would declare all three such as

Dim NumberOne, NumberTwo, Answer as Integer

NumberOne = TextBox1.Text
NumberTwo=TextBox2.Text
Answer=Textbox3.Text

NumberOne - NumberTwo = Answer

my syntax is prob wrong because I havent done this in a few months, but along the lines of that
This. I sometimes also use a label for the answer.
Yeah, that sounds about right but it's been about a year since I last used Visual Studios lol. Can't he do a drop down that assign an operator (+,-, /, *) instead of doing something static like that? I forgot the exact syntax but let's say + is selected, the statement would go like this... If plus is selected then numberone + numbertwo = answer and then follow with Else if's for subtraction, division, multiplication?
 
Originally Posted by gregbutler20

Originally Posted by LuckyLuchiano

What I use to do was have 3 text boxes and a "Calculate" button
1st 2 text boxes are for the numbers 3rd is for the answer

I would declare all three such as

Dim NumberOne, NumberTwo, Answer as Integer

NumberOne = TextBox1.Text
NumberTwo=TextBox2.Text
Answer=Textbox3.Text

NumberOne - NumberTwo = Answer

my syntax is prob wrong because I havent done this in a few months, but along the lines of that
This. I sometimes also use a label for the answer.
Yeah, that sounds about right but it's been about a year since I last used Visual Studios lol. Can't he do a drop down that assign an operator (+,-, /, *) instead of doing something static like that? I forgot the exact syntax but let's say + is selected, the statement would go like this... If plus is selected then numberone + numbertwo = answer and then follow with Else if's for subtraction, division, multiplication?
 
Originally Posted by seniosoul

i don't know how to program, but learning is no problem, where should i start.
I talked to my cousin in law, whos a math teacher, she told me to write out an algorithm, and that is done.
where should i get the knowledge, what language, C, C+, C++?
i just got Visual Studio, I guess i'm ready.

C+ ? Didn't even know that existed
laugh.gif


All my classes were in C++. Learn OOP. Then, all languages are (pretty much) the same (i did say pretty much).
Also, what do you want to program for? Software? Web? is it to find a job or just for fun?
 
Originally Posted by seniosoul

i don't know how to program, but learning is no problem, where should i start.
I talked to my cousin in law, whos a math teacher, she told me to write out an algorithm, and that is done.
where should i get the knowledge, what language, C, C+, C++?
i just got Visual Studio, I guess i'm ready.

C+ ? Didn't even know that existed
laugh.gif


All my classes were in C++. Learn OOP. Then, all languages are (pretty much) the same (i did say pretty much).
Also, what do you want to program for? Software? Web? is it to find a job or just for fun?
 
Originally Posted by ebpo

Originally Posted by seniosoul

i don't know how to program, but learning is no problem, where should i start.
I talked to my cousin in law, whos a math teacher, she told me to write out an algorithm, and that is done.
where should i get the knowledge, what language, C, C+, C++?
i just got Visual Studio, I guess i'm ready.

C+ ? Didn't even know that existed
laugh.gif


All my classes were in C++. Learn OOP. Then, all languages are (pretty much) the same (i did say pretty much).
Also, what do you want to program for? Software? Web? is it to find a job or just for fun?
c'mon ebpo, cut me some slack
laugh.gif
guess i meant to put C#
I'll read up on OOP and check back in.
 
Back
Top Bottom