Hi,
Believe me, I really do try and not abuse the generousity of everyone on this forum. Without it I, and many others, would surely be spending countless more hours trying to find answers. Let me assure all that when I ask a question it is only after many hours(sometimes literally days worth of time) of searching and trying as much as possible. For me I expect this as part of the learning curve.
But Am stumped once more I guess.
The two pertinent forms are :
Transaction - based on trans table (holds all transaction records)
tapAdd_Trans - based on trans==>allocation_tbl-->prod set (details of each transaction)
I have three fields on the form tapAdd_Trans which reflect a transaction
process(numerical).
Total Allocation (TTotal_Amt)--the total amount of transaction which is user entered.
Allocation total amount(c_allo_total)--the sum of the allocations for a single
transaction--a calculated field in the form's field properties.
Unallocated (cUnalloc)--the amount of dollars remaining that has not been allocated yet--a calculated field in the forms field properties.
These fields do exactly what they are supposed to do....but there is a problem.
When a transaction has been entered in the transaction form (insert button) and allocations have been entered for this transaction in the tapAdd_Trans form (insert button) and then saved and closed , the very next transaction entry will retain the prior "Allocation total amount" which is the c_all_total calculated field. The last allocation product will many times appear too. Sometimes the prior c_allo_total just shows up on the next transaction temporarily when another transaction is made as when new allocations are entered into the tapAdd_Trans form the calculations will be made but they are not always permanent---once the tapAdd_Trans form is closed and reopened many times all is as it should be...but not always. I cannot make it consistantly do much of anything except mess things up.
example:
First transaction: A total amount of $1000.00 is entered into form tapAdd_Trans.
An allocation of $250.00 is made for some product.
Ttotal_Amt shows $1000.00
C_allo_total shows $250.00
cUnalloc shows $750.00
Which is good.
Second transaction:
Now when the Insert button on the Transaction form is used to bring up the tapAdd_Trans form in order to enter a new transaction the c_allo_total still shows $250.00 and as a result the cUnalloc shows ($250.00)<--Negative. The Ttotal_Amt shows $0.00 . (The negative number in the cUnalloc tells me that it is not the problem). Sometimes, but not always, the last allocation will show up as well.
Enter in a total amount of $100.00 . cUnalloc now shows ($150.00). The C_allo_total still shows $250.00 . And a prior allocation may be present.
Close tapAdd_Trans before any additional allocation is made to this transaction.
Reopen the transaction just made and the calculated fields show what they are supposed to. Although when a prior allocation existed it will persist and messes things up as it should not be there of course.
Of course after reading all that I wrote I realize that the calculated fields most likely are not at fault but the prior allocations.....
As usual, I have attached a sample database of this for anyone who has the time, inclination, or knowledge to help me with this.
I added a red button to the Transaction form that only opens tapAdd_Trans for a new record--figured this might help in eliminating possible problems with the script that is on the Insert button that normally would be used. The problem exists when using either button although less with the new red one. If the red one is used additional info has to be entered when adding a transaction such as account type, company(vendor), besides the total dollar amount--the normal Insert button fills a few things in as default.
To easily get the problem to occur in a consistant manner, open the Transaction form, doubleclick(or highlight and press the Change button) on the one record that is entered--and then close it with either the Cancel or Close button. Then enter a new transaction by using the Insert or Red colored button.
If no one has the time to actually look at the database, then perhaps a bit a direction would be enough (of course this assumes that someone can actually understand what I wrote).
Thanks,
Mike
Believe me, I really do try and not abuse the generousity of everyone on this forum. Without it I, and many others, would surely be spending countless more hours trying to find answers. Let me assure all that when I ask a question it is only after many hours(sometimes literally days worth of time) of searching and trying as much as possible. For me I expect this as part of the learning curve.
But Am stumped once more I guess.
The two pertinent forms are :
Transaction - based on trans table (holds all transaction records)
tapAdd_Trans - based on trans==>allocation_tbl-->prod set (details of each transaction)
I have three fields on the form tapAdd_Trans which reflect a transaction
process(numerical).
Total Allocation (TTotal_Amt)--the total amount of transaction which is user entered.
Allocation total amount(c_allo_total)--the sum of the allocations for a single
transaction--a calculated field in the form's field properties.
Unallocated (cUnalloc)--the amount of dollars remaining that has not been allocated yet--a calculated field in the forms field properties.
These fields do exactly what they are supposed to do....but there is a problem.
When a transaction has been entered in the transaction form (insert button) and allocations have been entered for this transaction in the tapAdd_Trans form (insert button) and then saved and closed , the very next transaction entry will retain the prior "Allocation total amount" which is the c_all_total calculated field. The last allocation product will many times appear too. Sometimes the prior c_allo_total just shows up on the next transaction temporarily when another transaction is made as when new allocations are entered into the tapAdd_Trans form the calculations will be made but they are not always permanent---once the tapAdd_Trans form is closed and reopened many times all is as it should be...but not always. I cannot make it consistantly do much of anything except mess things up.
example:
First transaction: A total amount of $1000.00 is entered into form tapAdd_Trans.
An allocation of $250.00 is made for some product.
Ttotal_Amt shows $1000.00
C_allo_total shows $250.00
cUnalloc shows $750.00
Which is good.
Second transaction:
Now when the Insert button on the Transaction form is used to bring up the tapAdd_Trans form in order to enter a new transaction the c_allo_total still shows $250.00 and as a result the cUnalloc shows ($250.00)<--Negative. The Ttotal_Amt shows $0.00 . (The negative number in the cUnalloc tells me that it is not the problem). Sometimes, but not always, the last allocation will show up as well.
Enter in a total amount of $100.00 . cUnalloc now shows ($150.00). The C_allo_total still shows $250.00 . And a prior allocation may be present.
Close tapAdd_Trans before any additional allocation is made to this transaction.
Reopen the transaction just made and the calculated fields show what they are supposed to. Although when a prior allocation existed it will persist and messes things up as it should not be there of course.
Of course after reading all that I wrote I realize that the calculated fields most likely are not at fault but the prior allocations.....
As usual, I have attached a sample database of this for anyone who has the time, inclination, or knowledge to help me with this.
I added a red button to the Transaction form that only opens tapAdd_Trans for a new record--figured this might help in eliminating possible problems with the script that is on the Insert button that normally would be used. The problem exists when using either button although less with the new red one. If the red one is used additional info has to be entered when adding a transaction such as account type, company(vendor), besides the total dollar amount--the normal Insert button fills a few things in as default.
To easily get the problem to occur in a consistant manner, open the Transaction form, doubleclick(or highlight and press the Change button) on the one record that is entered--and then close it with either the Cancel or Close button. Then enter a new transaction by using the Insert or Red colored button.
If no one has the time to actually look at the database, then perhaps a bit a direction would be enough (of course this assumes that someone can actually understand what I wrote).
Thanks,
Mike
Comment