Results 1 to 2 of 2
  1. #1
    MrRud is offline Novice
    Windows 7 64bit Access 2003
    Join Date
    May 2011
    Posts
    1

    [I'm a newbie] Adding the content of 2 cells in Mask with Macro

    Hi guys.



    I have a problem: I created a table from a DB and a mask: i Wanted to create a macro that writes in a column the sum of 2 different elements of another column.

    Example:
    I have this series of numbers:

    78
    56
    95
    23
    14
    75
    63

    I want to create a macro that writes in another column the current element of the record with the current - x element, it would be something like this:

    78 -
    56 -
    95 95 + 78
    23 23 + 56

    etc.

    Thanks for your help

  2. #2
    NTC is offline VIP
    Windows Vista Access 2007
    Join Date
    Nov 2009
    Posts
    2,392
    No way, as currently constructed. There needs to be some ID data that cross references records so a db would know that 78 goes with the 95. The positional order is not sufficient - there must be data in the records themselves that cross references.

    Macros are not in general what you should be focusing on. Math & data manipulation can occur via queries or via VBA triggered in controls in forms. Either approach is viable and will depend on whether you do this auto math during human data entry (at the form level) or after entry when working with a fixed table (query).

    Hope this helps.

Please reply to this thread with any new information or opinions.

Similar Threads

  1. Adding Filter Using Macro
    By TxTcher in forum Forms
    Replies: 1
    Last Post: 02-05-2013, 02:16 AM
  2. Report cells and columns
    By romadm in forum Reports
    Replies: 0
    Last Post: 01-20-2011, 01:53 PM
  3. Replies: 0
    Last Post: 01-12-2011, 12:43 PM
  4. Bold Cells
    By jcsports31 in forum Access
    Replies: 12
    Last Post: 09-10-2010, 12:15 PM
  5. Newbie input mask Q and paswords setting
    By Cincity in forum Programming
    Replies: 2
    Last Post: 08-01-2010, 12:42 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Other Forums: Microsoft Office Forums