Click to See Complete Forum and Search --> : Math


The Matrix
February 14th, 2000, 10:49 PM
I am trying to make a program for my math class that msgbox's me the answer. I want text1 for the first number, and i want text2 the variable and text3 the answer. This is a common math problem: 5y = 430
now how do i msgbox me back what "y" means. First I have to divide text3 with text1. Sorry if this is confusing

Lothar Haensler
February 15th, 2000, 01:24 AM
>Sorry if this is confusing

well, it is, but I'm going to try to answer anyway :-)

msgbox "y is " & Text3.Text / Text1.Text

AndyK
February 15th, 2000, 09:31 AM
this is the code to calculate the y value (what grade are you in? by the way)

y = Text2 / Text1
MsgBox y



Don't forget to trap error (if not a number)
you can use something like If Not IsNumeric(Text1) then msgbox "not a number"