Running Totals on Forms

  • Thread starter BarbS via AccessMonster.com
  • Start date
B

BarbS via AccessMonster.com

I have built a DB that contains several accounts with different FY budgets in
each. I would like to show the balance of those accounts, and reflect
entries as they are made in the form. This way the user will know when the
funds in one acccount are getting low, and select another account before
making futher entries. Does any one know if there a way to build a control
box that would show a running $ balance when a form is filled out? Or, is
there another way to do this? Thank you for you help. Barb
 
T

tkelley via AccessMonster.com

Search for this in Access Help:

Calculate a running sum (cumulative total)

If you don't have access to the help for some reason, reply and I'll past it
in.
 
B

BarbS via AccessMonster.com

I'm sorry, but I read several of the help topics under cumulative and didn't
see on that would return a running total. I'd really appreciate it if you'd
help me find it? Thank you, barb
Search for this in Access Help:

Calculate a running sum (cumulative total)

If you don't have access to the help for some reason, reply and I'll past it
in.
I have built a DB that contains several accounts with different FY budgets in
each. I would like to show the balance of those accounts, and reflect
[quoted text clipped - 3 lines]
box that would show a running $ balance when a form is filled out? Or, is
there another way to do this? Thank you for you help. Barb
 
T

tkelley via AccessMonster.com

Oops. My bad. I was thinking reports ... not forms. Mea culpa.

Let me slow down and re-read this and give it some thought ... I'll follow up
soon.
I'm sorry, but I read several of the help topics under cumulative and didn't
see on that would return a running total. I'd really appreciate it if you'd
help me find it? Thank you, barb
Search for this in Access Help:
[quoted text clipped - 8 lines]
 
B

BarbS via AccessMonster.com

Thank you!
Oops. My bad. I was thinking reports ... not forms. Mea culpa.

Let me slow down and re-read this and give it some thought ... I'll follow up
soon.
I'm sorry, but I read several of the help topics under cumulative and didn't
see on that would return a running total. I'd really appreciate it if you'd
[quoted text clipped - 5 lines]
 
T

tkelley via AccessMonster.com

Okay, so at the top of the form there would be a place where each acct is
listed, each with it's current balance? The user selects one of those accts.
Then there is a subform where entries are made, and dollars applied to that
selected acct. Each time dollars are applied to that acct, it's balance will
dwindle, and you'd like to know the balance after each entry.

Do I understand correctly?
Thank you!
Oops. My bad. I was thinking reports ... not forms. Mea culpa.
[quoted text clipped - 6 lines]
 
B

BarbS via AccessMonster.com

Yes tht is correct
Okay, so at the top of the form there would be a place where each acct is
listed, each with it's current balance? The user selects one of those accts.
Then there is a subform where entries are made, and dollars applied to that
selected acct. Each time dollars are applied to that acct, it's balance will
dwindle, and you'd like to know the balance after each entry.

Do I understand correctly?
Thank you!
[quoted text clipped - 3 lines]
 
B

BarbS via AccessMonster.com

In other words, I have X amount of $ in an account, what is remaining in that
account after you subtract of balance. Does this make since?
Yes tht is correct
Okay, so at the top of the form there would be a place where each acct is
listed, each with it's current balance? The user selects one of those accts.
[quoted text clipped - 9 lines]
 
T

tkelley via AccessMonster.com

Here's where I would start:

--Your Acct list is a listbox. The rowsource for that listbox is a query.
The 1st column is your Acct Name; the 2nd column is the Acct Balance.

--When you make an entry removing funds from the account by making an entry
in your subform, or however you plan to design your entry boxes, on the after
update event of that record, you do a listbox.requery. That should pull back
the updated acct balance into the second column.

--Another thing I would do is to put in a validation check in the before the
amount gets applied:

If me.FundsToRemove > me.listbox.column(1,me.listbox.listindex) then
msgbox "There are not enough funds in the " & _
me.listbox.column(0,me.listbox.listindex) & _
" account. Please select another account."
(or this could be a yes/no if you allow accounts to go red)
EndIf

Remeber, listboxes are zero-based, so their first column is 0.

Play around with that idea and see how you like it.

In other words, I have X amount of $ in an account, what is remaining in that
account after you subtract of balance. Does this make since?
Yes tht is correct
[quoted text clipped - 3 lines]
 
B

BarbS via AccessMonster.com

Just got home form work. Will give this a try as soon as I can and let you
know how it goes. thank you so much
Here's where I would start:

--Your Acct list is a listbox. The rowsource for that listbox is a query.
The 1st column is your Acct Name; the 2nd column is the Acct Balance.

--When you make an entry removing funds from the account by making an entry
in your subform, or however you plan to design your entry boxes, on the after
update event of that record, you do a listbox.requery. That should pull back
the updated acct balance into the second column.

--Another thing I would do is to put in a validation check in the before the
amount gets applied:

If me.FundsToRemove > me.listbox.column(1,me.listbox.listindex) then
msgbox "There are not enough funds in the " & _
me.listbox.column(0,me.listbox.listindex) & _
" account. Please select another account."
(or this could be a yes/no if you allow accounts to go red)
EndIf

Remeber, listboxes are zero-based, so their first column is 0.

Play around with that idea and see how you like it.
In other words, I have X amount of $ in an account, what is remaining in that
account after you subtract of balance. Does this make since?
[quoted text clipped - 4 lines]
 
Top