• Update based on Modifications (Access 2000 SR-1)

    Home » Forums » AskWoody support » Productivity software by function » MS Access and database help » Update based on Modifications (Access 2000 SR-1)

    • This topic has 1 reply, 2 voices, and was last updated 22 years ago.
    Author
    Topic
    #386336

    Information gathering:

    I have a database with a COST and a Comments Column

    I would like some suggestions on updating a field when changes are made in any of these fields. IF a Comment was updated, then a ‘ * ‘ is placed in the Changes Field. If a COST was updated, then a ‘ $ ‘ is placed. If both, then ‘ *$ ‘.

    Thanks

    Paul

    Viewing 0 reply threads
    Author
    Replies
    • #670022

      To do that sort of thing you will need to use a form – editing at the table level doesn’t trigger events. On a form you can use the AfterUpdate event for a text box to determine if a field has changed – that isn’t entirely foolproof though, as a user may make a change and then undo it. Probably a better approach would be to use the OldValue property of bound controls to determine in code if either or both have changed. That would best be triggered with the BeforeUpdate event for the form. You might also look at capturing the date and time of the most recent change, and the user name who made the change, assuming you have user security activated.

    Viewing 0 reply threads
    Reply To: Update based on Modifications (Access 2000 SR-1)

    You can use BBCodes to format your content.
    Your account can't use all available BBCodes, they will be stripped before saving.

    Your information: