PDA

View Full Version : Percentages



blackie42
10-05-2007, 01:56 AM
My task:

Create a user form with some text boxes (customer, account, date) which is used to populate a number of sheets (col1,2, & 3)depending on the following.

Another text box with money amount which automatically calulates the percentage to be applied to a particular sheet. Percentage split will be the same however much the money is thats entered

e.g.

?7000 split 40% sheet 1 (4th col) -> ?2800
20% sheet 2 ( ") -> ?1400
10% sheet 3 (") -> ?700
15% sheet 4 (") -> ?1050
15% sheet 5 (") -> ?1050

I want to set command button to update sheets at next available row (on each sheet) with correct percentages.

Any help appreciated

thanks

Jon

Simon Lloyd
10-05-2007, 03:19 AM
Jon, what have you come up with so far, post what you have then we can help you with specific problems you come across!

blackie42
10-05-2007, 03:58 AM
Hi Simon,

Haven't really got started yet - was just hoping for some ideas really.

I can create the forms and can handle the change events and parse the contents of the 'text box' (numerically to the correct column).

Just have tried to convert the contents of a text box in to 5 different parts - and haven't used any percentage calcs (although I suspect theres some code knocking about that will do it)

Any tips/ideas/hints will be useful

thanks

tpoynton
10-05-2007, 06:41 AM
the way I handle % calculations is to simply multiply by the desired % - .2 is 20%, .05 is 5%, etc.

sorry if this seems basic, but the code to do this is quite straight forward. the more difficult/time consuming part is writing the value of the textbox to the 5 sheets; converting to a % of original value is the easy part. As Simon suggested, posting what you have gotten thus far, with mock up of what you want output to look like will help you get the most targeted help.