Results 1 to 4 of 4
  1. #1
    bluereef is offline Novice
    Windows 7 64bit Access 2010 32bit
    Join Date
    May 2011
    Posts
    2

    Button to copy contents of one field into another field on the same form

    Hi



    I am new to Access 2010 and still coming to terms with a lot of its functions etc.

    However, I have created a database to store information about members of my local Kayaking club. This is fairly detailed and includes addresses and personal information.

    One of the sections on the form is details on next of kin. In most instances the address fields for the next of kin are the same as those for the member himself. Rather than retyping the same information out again I want to put a control button next to each address field which - when pressed, takes the info from [Address 1] and sticks it in [NK-Address 1]. I thought this would be fairly simple but I am obviously doing something wrong.

    Can anyone help - in terms that a beginner is going to understand. !!

    Thanks

  2. #2
    RuralGuy's Avatar
    RuralGuy is offline Administrator
    Windows 7 64bit Access 2010 32bit
    Join Date
    Mar 2007
    Location
    8300' in the Colorado Rocky Mountains
    Posts
    12,922
    Your button should have code similar to:
    Me.[NK-Address 1] = Me.[Address 1]
    ...assuming those are the names of the two controls involved.

  3. #3
    bluereef is offline Novice
    Windows 7 64bit Access 2010 32bit
    Join Date
    May 2011
    Posts
    2

    Button Problem

    Many thanks - seem to have solved the problem. Stangely it worked when I put the code directly into the page - but didn't work when I used the expression builder. Its probably me - still learning . . . thanks again.

  4. #4
    RuralGuy's Avatar
    RuralGuy is offline Administrator
    Windows 7 64bit Access 2010 32bit
    Join Date
    Mar 2007
    Location
    8300' in the Colorado Rocky Mountains
    Posts
    12,922
    Great! Are you ready to use the Thread Tools and mark this thread as Solved?

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

Similar Threads

  1. Copy field from form to another field in same form
    By anandram in forum Programming
    Replies: 8
    Last Post: 05-08-2011, 02:49 PM
  2. Replies: 0
    Last Post: 03-29-2011, 04:11 PM
  3. Copy contents of one field to another
    By 10 Gauge in forum Forms
    Replies: 4
    Last Post: 02-11-2011, 09:51 AM
  4. Copy form field to another table
    By Dega in forum Forms
    Replies: 6
    Last Post: 05-21-2010, 02:57 PM
  5. Remove contents from each field
    By nancyszn in forum Access
    Replies: 7
    Last Post: 08-06-2009, 03:41 PM

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