|
Search Tech-Forums - link takes you to our Forum's search page. Note: The following is only a text archive! To view the actual forum discussion, please visit our website at http://www.tech-forums.net Pages:1 Visual Basic Calculator(Click here to view the original thread with full colors/images)Posted by: dawizhacker I need a the code for a very basic calculator or how to make one. Must include: Clear + - / * = 1-9 and 0. A link or the code would be nice. :) Posted by: jaeusm Do your own homework. Posted by: dawizhacker Lol who said it's homework? I quess it's quite easy to make it myself but I'm just way, way to **** lazy. Posted by: ryno Well, what you could do is create four functions for each mathematical operator (multiplication, addition, subtraction, division) which takes in two integers (or doubles, floats, whatever you need to calculate). The user will enter the first number and click on a mathematical operator. When that operator is clicked you will know which function to use. The user will enter the second number and click on either another operator or the equals button. At this point you will pass the two numbers to the pertinent function and return the result to the user. Easy as pi. PS: This is a very common homework question, so don't expect anybody to give you any code. Posted by: dawizhacker Yea... I kinda did it already, but Thx for the info :) vBulletin Copyright ©2000 - 2003, Jelsoft Enterprises Limited. PPC Management vB Easy Archive Final - Created by Xenon |