I cant seem to get this application to become a reality.Maybe someone can help me. I need to write an application for a friend who owns his own Tollgate Enterprise.The tollgate is calculated as follows:
For a vehicle with 4 or less wheels, the price is a basic charge of $7 plus 1.5 cents per KG per wheel.For more than 4 wheels the basic charge is adjusted by a factor.The factor is determined as follows:
For 5 or 6 wheels the factor is 1.5 and for 6 wheels,the factor is 2.
If we use a factor of 1 for vechicles with 1 to 4 wheels,the toll payable for any vechicle can be calculated using this formula I formulated. 7 . Factor + 0.015 x AWM (AWM is the average wheel mass and can be calculated by dividing the total mass of the vechicle by the number of wheels).
I want to write event handlers for two buttons on the form.The names of the relevant components are sedWheels,sedMass,lblToll,btnCalculate and btnClear.
Im just not sure how to put this formula a reality within the calculate button.Also im not sure how to clear the edit fields afterwards.
Please if someone can help , i have almost given up.