Hello Everyone.

I'm working on a Calculator for a game. So i decided to try to code the calculator to be as user friendly as possible.

What i need help with is the following;

Changing the effects of another form dependent on the button i click on my mainform.
Example;

If i have two forms, MainForm and SubForm. In the MainForm i have a textbox, txtTotal, two buttons, btnAdd and btnSubtract.

In the SubForm i have a Textbox, named txtValue, two buttons, btnOK and btnCancel.

If the btnAdd from the MainForm is clicked, SubForm Loads and the value of txtValue will be ADD to the txtTotal when the btnOK is clicked.

So e.g. txtTotal already have a value of 5, in txtValue(from SubForm) i put in an additional 5 and hit ok - txtTotal will now change its value to 10.

However if the btnSubtract is clicked, SubForm Loads and the value of txtValue will be Subtracted from the txtTotal when the btnOK is clicked.

So e.g. txtTotal will now be 0, if SubForm.txtValue and MainForm.txtTotal is 5.

Also would like to know how to change a image dependent on MainForm btns. Example the btnAdd will set the background of SubForm to "C:\Some location" and the btnSubtract will set the background of SubForm to "C:\Some other Location"

also does any of you know any useful links to a guide about Class's and effects ?

You just gave me 2 completely useless links ?

One for Mac and another for some audio program?

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.