+ Reply to Thread
Results 1 to 6 of 6

Sum dynamic fields

  1. #1
    Registered User
    Join Date
    09-30-2008
    Location
    USA
    MS-Off Ver
    2010
    Posts
    36

    Sum dynamic fields

    Here is my problem today.
    I have 5 currency fields that are filled in order when I add records to the database.
    Amount1, Amount2, Amount3, Amount4 and Amount5.

    I need to sum all these fields into another field called SubTotal.

    I need to put in the SubTotal field the Amount1 if no other Amount field contains data, or
    Amount1 plus Amount2 if only these fields contain data, or
    Amount1 plus Amount2 plus Amount3…
    In other words, the SubTotal field will be the adjusted according to the data of these 5 previous fields.

    How can I do this please?
    Thank you.
    Last edited by WT2008; 05-11-2010 at 05:19 PM.

  2. #2
    Forum Contributor
    Join Date
    04-23-2009
    Location
    IOWA
    MS-Off Ver
    2010 Professional
    Posts
    270

    Re: Sum dynamic fields ... please help!

    Where is the subtotal field located, a form, a report, a query?
    "I am not a rocket scientist, I am a nuclear engineer." - Split_atom18
    If my advice has been helpful to you, then please help me by clicking on the "Star" and adding to my reputation, Thanks!

  3. #3
    Registered User
    Join Date
    09-30-2008
    Location
    USA
    MS-Off Ver
    2010
    Posts
    36

    Re: Sum dynamic fields ... please help!

    Hello split_atom18,
    The subtotal field is located in a form.
    Thanks

  4. #4
    Forum Contributor
    Join Date
    04-23-2009
    Location
    IOWA
    MS-Off Ver
    2010 Professional
    Posts
    270

    Re: Sum dynamic fields

    I would just create an unbound field, and put the following in the control source.

    Please Login or Register  to view this content.


    Hope this helps,

    Dan

  5. #5
    Registered User
    Join Date
    09-30-2008
    Location
    USA
    MS-Off Ver
    2010
    Posts
    36

    Re: Sum dynamic fields

    That was great! Thank you for your help.

  6. #6
    Forum Contributor
    Join Date
    04-23-2009
    Location
    IOWA
    MS-Off Ver
    2010 Professional
    Posts
    270

    Re: Sum dynamic fields

    No problem at all, Glad I could help! Be sure to mark your thread as solved, by editing your first post and selecting solved pre-fix.

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1