You can do this as you've indicated in your first post and here's how (but I think there is a better way, which I will mention at the end).
- Regardless, I think your deptartment table should have a primary key that you can relate to tblPercent (a table you create with ID and PCT fields & do not use the word percent). This might help in future (e.g. to manage department percentages). Easiest way would be to create an autonumber field for [Department].[ID]. If Department is already a PK, remove that key and create an index on that field instead (No Dupes). Make PCT field a Double data type with Fixed format). Paste Append your new autonumber list from Department into the ID field of tblPercent, then enter each dept percent in the PCT field. Add a Total row in tblPercent (see Totals button on Home tab of the ribbon) to ensure you do not exceed 100 percent.
- you'd need one textbox for the amount (e.g. txtAmt), and one for each department allocation amount. In each unbound allocation textbox, enter =[txtAmt]*DLookUp("PCT","tblPercent","DEPT=1") as the controlsource property, but you would have to change the 1 to the correct number for each department. There's the rub - 55 is too many controls to manage this way, and a textbox cannot be set to a query field. You have to use a function of some sort. If the amount textbox gets updated and loses focus, the allocation calculation should automatically update. However, depending on what actions a user can take, it might be possible for the user to commit these values before they update. So worse yet, you would have to ensure each allocation textbox can recalculate. Also, any changes to the number of departments or their values (1, 2, 3, etc.) would make for a lot of work.
I think this is better:
As mentioned, create and set up the tables. Add a subform to your form and have this form display as a datasheet that cannot be edited by the user. On the main form, have your unbound textbox for the amount and a button to run a click event. The query for this subform datasheet would have a field to calculate the allocation (the percent times the textbox amount as done above) so that it gives you an allocation for each department. You would have 55 rows in the datasheet if you have 55 departments. Your button code simply exits if there is no value in the amount textbox, otherwise, it requeries the subform datasheet to show the new values.
This way, you can easily add as many fields to the datasheet from any other tables by building the query as needed. If you add or delete departments, the datasheet rows will adjust accordingly. You can easily negate any percent by setting it to zero, effectively obsoleting any department. If the subform seems daunting, you would probably do OK using a form wizard as long as you have your main form, subform and query built first.
BTW, this took so long to compose that I might seem out of sequence with the responses.